SSHKeyManager Class
Properties Methods Events Configuration Settings Errors
The SSHKeyManager class stores information about SSH keys.
Class Name
SecureBlackboxLite_SSHKeyManager
Procedural Interface
secureblackboxlite_sshkeymanager_open(); secureblackboxlite_sshkeymanager_close($res); secureblackboxlite_sshkeymanager_register_callback($res, $id, $function); secureblackboxlite_sshkeymanager_get_last_error($res); secureblackboxlite_sshkeymanager_get_last_error_code($res); secureblackboxlite_sshkeymanager_set($res, $id, $index, $value); secureblackboxlite_sshkeymanager_get($res, $id, $index); secureblackboxlite_sshkeymanager_do_config($res, $configurationstring); secureblackboxlite_sshkeymanager_do_exportbytes($res, $keytype, $password); secureblackboxlite_sshkeymanager_do_exporttocert($res); secureblackboxlite_sshkeymanager_do_exporttocryptokey($res); secureblackboxlite_sshkeymanager_do_exporttofile($res, $keytype, $path, $password); secureblackboxlite_sshkeymanager_do_generate($res, $keyalgorithm, $scheme, $schemeparams, $keybits); secureblackboxlite_sshkeymanager_do_getkeyparam($res, $name); secureblackboxlite_sshkeymanager_do_getkeyparamstr($res, $name); secureblackboxlite_sshkeymanager_do_importbytes($res, $bytes, $password); secureblackboxlite_sshkeymanager_do_importfromcert($res); secureblackboxlite_sshkeymanager_do_importfromcryptokey($res); secureblackboxlite_sshkeymanager_do_importfromfile($res, $path, $password); secureblackboxlite_sshkeymanager_do_setkeyparam($res, $name, $value); secureblackboxlite_sshkeymanager_do_setkeyparamstr($res, $name, $valuestr);
Remarks
SSHKeyManager provides the capabilities of generating, storing, importing, and exporting SSH keys.
Property List
The following is the full list of the properties of the class with short descriptions. Click on the links for further details.
CertBytes | Returns raw certificate data in DER format. |
CertCA | Indicates whether the certificate has a CA capability (a setting in BasicConstraints extension). |
CertCAKeyID | A unique identifier (fingerprint) of the CA certificate's private key. |
CertCRLDistributionPoints | Locations of the CRL (Certificate Revocation List) distribution points used to check this certificate's validity. |
CertCurve | Specifies the elliptic curve of the EC public key. |
CertFingerprint | Contains the fingerprint (a hash imprint) of this certificate. |
CertFriendlyName | Contains an associated alias (friendly name) of the certificate. |
CertHandle | Allows to get or set a 'handle', a unique identifier of the underlying property object. |
CertHashAlgorithm | Specifies the hash algorithm to be used in the operations on the certificate (such as key signing) SB_HASH_ALGORITHM_SHA1 SHA1 SB_HASH_ALGORITHM_SHA224 SHA224 SB_HASH_ALGORITHM_SHA256 SHA256 SB_HASH_ALGORITHM_SHA384 SHA384 SB_HASH_ALGORITHM_SHA512 SHA512 SB_HASH_ALGORITHM_MD2 MD2 SB_HASH_ALGORITHM_MD4 MD4 SB_HASH_ALGORITHM_MD5 MD5 SB_HASH_ALGORITHM_RIPEMD160 RIPEMD160 SB_HASH_ALGORITHM_CRC32 CRC32 SB_HASH_ALGORITHM_SSL3 SSL3 SB_HASH_ALGORITHM_GOST_R3411_1994 GOST1994 SB_HASH_ALGORITHM_WHIRLPOOL WHIRLPOOL SB_HASH_ALGORITHM_POLY1305 POLY1305 SB_HASH_ALGORITHM_SHA3_224 SHA3_224 SB_HASH_ALGORITHM_SHA3_256 SHA3_256 SB_HASH_ALGORITHM_SHA3_384 SHA3_384 SB_HASH_ALGORITHM_SHA3_512 SHA3_512 SB_HASH_ALGORITHM_BLAKE2S_128 BLAKE2S_128 SB_HASH_ALGORITHM_BLAKE2S_160 BLAKE2S_160 SB_HASH_ALGORITHM_BLAKE2S_224 BLAKE2S_224 SB_HASH_ALGORITHM_BLAKE2S_256 BLAKE2S_256 SB_HASH_ALGORITHM_BLAKE2B_160 BLAKE2B_160 SB_HASH_ALGORITHM_BLAKE2B_256 BLAKE2B_256 SB_HASH_ALGORITHM_BLAKE2B_384 BLAKE2B_384 SB_HASH_ALGORITHM_BLAKE2B_512 BLAKE2B_512 SB_HASH_ALGORITHM_SHAKE_128 SHAKE_128 SB_HASH_ALGORITHM_SHAKE_256 SHAKE_256 SB_HASH_ALGORITHM_SHAKE_128_LEN SHAKE_128_LEN SB_HASH_ALGORITHM_SHAKE_256_LEN SHAKE_256_LEN . |
CertIssuer | The common name of the certificate issuer (CA), typically a company name. |
CertIssuerRDN | A collection of information, in the form of [OID, Value] pairs, uniquely identifying the certificate issuer. |
CertKeyAlgorithm | Specifies the public key algorithm of this certificate. |
CertKeyBits | Returns the length of the public key. |
CertKeyFingerprint | Returns a fingerprint of the public key contained in the certificate. |
CertKeyUsage | Indicates the purposes of the key contained in the certificate, in the form of an OR'ed flag set. |
CertKeyValid | Returns True if the certificate's key is cryptographically valid, and False otherwise. |
CertOCSPLocations | Locations of OCSP (Online Certificate Status Protocol) services that can be used to check this certificate's validity, as recorded by the CA. |
CertOrigin | Returns the origin of this certificate. |
CertPolicyIDs | Contains identifiers (OIDs) of the applicable certificate policies. |
CertPrivateKeyBytes | Contains the certificate's private key. |
CertPrivateKeyExists | Indicates whether the certificate has an associated private key. |
CertPrivateKeyExtractable | Indicates whether the private key is extractable. |
CertPublicKeyBytes | Contains the certificate's public key in DER format. |
CertSelfSigned | Indicates whether the certificate is self-signed (root) or signed by an external CA. |
CertSerialNumber | Returns the certificate's serial number. |
CertSigAlgorithm | Indicates the algorithm that was used by the CA to sign this certificate. |
CertSubject | The common name of the certificate holder, typically an individual's name, a URL, an e-mail address, or a company name. |
CertSubjectKeyID | Contains a unique identifier (fingerprint) of the certificate's private key. |
CertSubjectRDN | A collection of information, in the form of [OID, Value] pairs, uniquely identifying the certificate holder (subject). |
CertValidFrom | The time point at which the certificate becomes valid, in UTC. |
CertValidTo | The time point at which the certificate expires, in UTC. |
CryptoKeyAlgorithm | The algorithm of the cryptographic key. |
CryptoKeyBits | The length of the key in bits. |
CryptoKeyExportable | Returns True if the key is exportable (can be serialized into an array of bytes), and False otherwise. |
CryptoKeyHandle | Allows to get or set a 'handle', a unique identifier of the underlying property object. |
CryptoKeyID | Provides access to a storage-specific key identifier. |
CryptoKeyIV | The initialization vector (IV) of a symmetric key. |
CryptoKeyKey | The byte array representation of the key. |
CryptoKeyNonce | A nonce value associated with a key. |
CryptoKeyPrivate | Returns True if the object hosts a private key, and False otherwise. |
CryptoKeyPublic | Returns True if the object hosts a public key, and False otherwise. |
CryptoKeySubject | Returns the key subject. |
CryptoKeySymmetric | Returns True if the object contains a symmetric key, and False otherwise. |
CryptoKeyValid | Returns True if this key is valid. |
KeyAlgorithm | Specifies the key algorithm. |
KeyBits | The number of bits in the key: the more the better, 2048 or 4096 are typical values. |
KeyComment | The comment for the public key. |
KeyCurve | Specifies the elliptical curve when EC cryptography is used. |
KeyDSSG | The G (Generator) parameter of the DSS signature key. |
KeyDSSP | The P (Prime) parameter of the DSS signature key. |
KeyDSSQ | The Q (Prime Factor) parameter of the DSS signature key. |
KeyDSSX | The X (Private key) parameter of the DSS signature key. |
KeyDSSY | The Y (Public key) parameter of the DSS signature key. |
KeyECCD | The value of the secret key (the order of the public key, D) if elliptic curve (EC) cryptography is used. |
KeyECCQX | The value of the X coordinate of the public key if elliptic curve (EC) cryptography is used. |
KeyECCQY | The value of the Y coordinate of the public key if elliptic curve (EC) cryptography is used. |
KeyEdPrivate | The value of the private key if EdDSA (Edwards-curve Digital Signature Algorithm) algorithm is used. |
KeyEdPublic | The value of the public key if EdDSA (Edwards-curve Digital Signature Algorithm) algorithm is used. |
KeyFingerprintMD5 | Contains the MD5 fingerprint (hash) of the key. |
KeyFingerprintSHA1 | Contains the SHA-1 fingerprint (hash) of the key. |
KeyFingerprintSHA256 | Contains the SHA-256 fingerprint (hash) of the key. |
KeyHandle | Allows to get or set a 'handle', a unique identifier of the underlying property object. |
KeyIsExtractable | Whether the key is extractable (e. |
KeyIsPrivate | Whether this key is a private key or not. |
KeyIsPublic | Whether this key is a public key or not. |
KeyKDFRounds | Returns the number of iterations of the Key Derivation Function (KDF) used to generate this key. |
KeyKDFSalt | The salt value used by the Key Derivation Function (KDF) to generate this key. |
KeyKeyFormat | Specifies the format in which the key is stored. |
KeyKeyProtectionAlgorithm | Specifies the key protection algorithm. |
KeyRSAExponent | Returns the e parameter (public exponent) of the RSA key. |
KeyRSAIQMP | Returns the iqmp parameter of the RSA key. |
KeyRSAModulus | Returns the m parameter (public modulus) of the RSA key. |
KeyRSAP | Returns the p parameter (first factor of the common modulus n) of the RSA key. |
KeyRSAPrivateExponent | Returns the d parameter (private exponent) of the RSA key. |
KeyRSAQ | Returns the q parameter (second factor of the common modulus n) of the RSA key. |
KeySubject | Specifies the public key owner (subject). |
Method List
The following is the full list of the methods of the class with short descriptions. Click on the links for further details.
Config | Sets or retrieves a configuration setting. |
ExportBytes | Writes the key to a memory buffer. |
ExportToCert | Exports the key to a certificate. |
ExportToCryptoKey | Exports the key to a crypto key object. |
ExportToFile | Writes key to file. |
Generate | Generates a new SSH key. |
GetKeyParam | Returns an algorithm-specific key parameter. |
GetKeyParamStr | Returns an algorithm-specific key parameter to a string. |
ImportBytes | Loads key from buffer. |
ImportFromCert | Loads a key from a certificate. |
ImportFromCryptoKey | Imports a key from a crypto key. |
ImportFromFile | Loads key from file. |
SetKeyParam | Sets an algorithm-specific key parameter. |
SetKeyParamStr | Sets an algorithm-specific key parameter. |
Event List
The following is the full list of the events fired by the class with short descriptions. Click on the links for further details.
Error | Information about errors during SSH key management. |
Notification | This event notifies the application about an underlying control flow event. |
Configuration Settings
The following is a list of configuration settings for the class with short descriptions. Click on the links for further details.
TempPath | Path for storing temporary files. |