![]() |
![]()
| ![]() |
![]()
NAMEOpenXPKI::Server::API2::Plugin::Cert::private_key COMMANDSget_private_key_for_certreturns an ecrypted private key for a certificate if the private key was generated on the CA during the certificate request process. Parameters are the same as for convert_private_key except that private_key must not be passed but is read from the datapool and cert_identifier is mandatory. convert_private_keyexpects a private key and converts it into another format. If a bundle with certificates is requested (PKCS12, JKS), the certificate to use as the end entity certificate must be given via identifier or as first element of chain.
If the input password does not decrypt the private key, an exception is thrown. private_key_exists_for_certChecks whether a corresponding CA-generated private key exists for the given certificate identifier (named parameter IDENTIFIER). Returns true if there is a private key, false otherwise. METHODSget_private_key_from_dbGets a private key from the database for a given certificate identifier by looking up the CSR serial of the certificate and extracting the private_key from the datapool. Returns undef if no key is available.
|