NPKIGetWrappedServerKey

Obtains a server private key cryptographically wrapped in the server's key storage key (formerly NWPKIGetWrappedServerKey).

Syntax

    #include "npki.h"
    
    NWRCODE NPKIGetWrappedServerKey(
       const NPKIContext     context,
       const unicode        *serverDN,
       const unicode        *serverCertificateName,
       pnuint32              wrappedKeySize,
       nuint8 const        **wrappedKey);
    

Parameters

context
(IN) Specifies the NPKI context for the request.
serverDN
(IN) Specifies the FDN of the server for which you want to get a private key.
serverCertificateName
(IN) Specifies which server key to retrieve.
wrappedKeySize
(OUT) Specifies the size of the cryptographically wrapped private key.
wrappedKey
(OUT) Points to the cryptographically wrapped private key.

Return Values

Returns 0 if successful, or an eDirectory or PKI error code if not successful.

See Also

NPKICreateServerCertificate, NPKIFindServerCertificateNames, NPKIServerCertificateName