Software: Apache. PHP/8.1.30 uname -a: Linux server1.tuhinhossain.com 5.15.0-151-generic #161-Ubuntu SMP Tue Jul 22 14:25:40 UTC uid=1002(picotech) gid=1003(picotech) groups=1003(picotech),0(root) Safe-mode: OFF (not secure) /usr/local/share/doc/openssl/html/man1/ drwxr-xr-x |
Viewing file: Select action/file-type:
NAMEopenssl-pkeyutl, pkeyutl - public key algorithm utility SYNOPSISopenssl pkeyutl [-help] [-in file] [-out file] [-sigfile file] [-inkey file] [-keyform PEM|DER|ENGINE] [-passin arg] [-peerkey file] [-peerform PEM|DER|ENGINE] [-pubin] [-certin] [-rev] [-sign] [-verify] [-verifyrecover] [-encrypt] [-decrypt] [-derive] [-kdf algorithm] [-kdflen length] [-pkeyopt opt:value] [-hexdump] [-asn1parse] [-engine id] [-engine_impl] DESCRIPTIONThe pkeyutl command can be used to perform public key operations using any supported algorithm. OPTIONS
NOTESThe operations and options supported vary according to the key algorithm and its implementation. The OpenSSL operations and options are indicated below. Unless otherwise mentioned all algorithms support the digest:alg option which specifies the digest in use for sign, verify and verifyrecover operations. The value alg should represent a digest name as used in the EVP_get_digestbyname() function for example sha1. This value is used only for sanity-checking the lengths of data passed in to the pkeyutl and for creating the structures that make up the signature (e.g. DigestInfo in RSASSA PKCS#1 v1.5 signatures). In case of RSA, ECDSA and DSA signatures, this utility will not perform hashing on input data but rather use the data directly as input of signature algorithm. Depending on key type, signature type and mode of padding, the maximum acceptable lengths of input data differ. In general, with RSA the signed data can't be longer than the key modulus, in case of ECDSA and DSA the data shouldn't be longer than field size, otherwise it will be silently truncated to field size. In other words, if the value of digest is sha1 the input should be 20 bytes long binary encoding of SHA-1 hash function output. RSA ALGORITHMThe RSA algorithm generally supports the encrypt, decrypt, sign, verify and verifyrecover operations. However, some padding modes support only a subset of these operations. The following additional pkeyopt values are supported:
DSA ALGORITHMThe DSA algorithm supports signing and verification operations only. Currently there are no additional options other than digest. Only the SHA1 digest can be used and this digest is assumed by default. DH ALGORITHMThe DH algorithm only supports the derivation operation and no additional options. EC ALGORITHMThe EC algorithm supports sign, verify and derive operations. The sign and verify operations use ECDSA and derive uses ECDH. Currently there are no additional options other than digest. Only the SHA1 digest can be used and this digest is assumed by default. X25519 ALGORITHMThe X25519 algorithm supports key derivation only. Currently there are no additional options. EXAMPLESSign some data using a private key:
Recover the signed data (e.g. if an RSA key is used):
Verify the signature (e.g. a DSA key):
Sign data using a message digest value (this is currently only valid for RSA):
Derive a shared secret value:
Hexdump 48 bytes of TLS1 PRF using digest SHA256 and shared secret and seed consisting of the single byte 0xFF:
SEE ALSOpkey(1), dgst(1), genrsa(1), EVP_PKEY_CTX_set_tls1_prf_md(3) COPYRIGHTCopyright 2006-2016 The OpenSSL Project Authors. All Rights Reserved. Licensed under the OpenSSL license (the "License"). You may not use this file except in compliance with the License. You can obtain a copy in the file LICENSE in the source distribution or at https://www.openssl.org/source/license.html. |
:: Command execute :: | |
--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0043 ]-- |