CERT_KEY_CONTEXT

The CERT_KEY_CONTEXT structure defines the CERT_KEY_CONTEXT_PROP_ID's pvData.

typedef struct _CERT_KEY_CONTEXT {
    DWORD            cbSize;
    HCRYPTPROV       hCryptProv;
    DWORD            dwKeySpec;
} CERT_KEY_CONTEXT, *PCERT_KEY_CONTEXT;
 

Members

cbSize
The size of the CERT_KEY_CONTEXT.
hCryptProv
A handle to the cryptographic service provider.
dwKeySpec
The specification of the private key to retrieve.

The following dwKeySpec values are defined in Wincrypt.h for the default provider:

#define AT_KEYEXCHANGE              1
#define AT_SIGNATURE                2

See Also

CertGetCertificateContextProperty, CertSetCertificateContextProperty