Skip to content

qie.getPrivateKey

Signature: qie.getPrivateKey(name)

Returns: java.security.PrivateKey privateKey - the private key object (java.security.PrivateKey)

Gets a private key by name.

Parameters

Type Name Description Default
String name the name of the private key

Example

var privateKey = qie.getPrivateKey('myPreviouslyUploadedPrivateKey');   // sun.security.rsa.RSAPrivateCrtKeyImpl
// Example usage: inspect key metadata
var privateKeyAlgorithm = privateKey.getAlgorithm();                    // RSA
var privateKeyFormat = privateKey.getFormat();                          // PKCS#8