CMSG_CTRL_KEY_AGREE_DECRYPT_PARA structure (wincrypt.h)
The CMSG_CTRL_KEY_AGREE_DECRYPT_PARA structure contains information about a key agreement recipient.
Syntax
typedef struct _CMSG_CTRL_KEY_AGREE_DECRYPT_PARA {
DWORD cbSize;
union {
HCRYPTPROV hCryptProv;
NCRYPT_KEY_HANDLE hNCryptKey;
} DUMMYUNIONNAME;
DWORD dwKeySpec;
PCMSG_KEY_AGREE_RECIPIENT_INFO pKeyAgree;
DWORD dwRecipientIndex;
DWORD dwRecipientEncryptedKeyIndex;
CRYPT_BIT_BLOB OriginatorPublicKey;
} CMSG_CTRL_KEY_AGREE_DECRYPT_PARA, *PCMSG_CTRL_KEY_AGREE_DECRYPT_PARA;
Members
cbSize
The size, in bytes, of this data structure.
DUMMYUNIONNAME
DUMMYUNIONNAME.hCryptProv
A handle to the cryptographic service provider (CSP) used to do the recipient key encryption and export. If NULL, the provider specified in CMSG_ENVELOPED_ENCODE_INFO is used. The CNG function NCryptIsKeyHandle is called to determine the union choice.
DUMMYUNIONNAME.hNCryptKey
A handle to the CNG CSP used to do the recipient key encryption and export. The CNG function NCryptIsKeyHandle is called to determine the union choice. New encrypt algorithms are only supported in CNG functions. The CNG function NCryptTranslateHandle will be called to convert the CryptoAPI CSP hCryptProv choice where necessary. We recommend that applications pass, to the hNCryptKey member, the CNG CSP handle that is returned from the NCryptOpenKey function.
dwKeySpec
Specifies the encrypted key. The encrypted key is the result of encrypting the content-encryption key. This member is not used when the hNCryptKey member is used.
pKeyAgree
A pointer to a CMSG_KEY_AGREE_RECIPIENT_INFO structure.
dwRecipientIndex
Indicates a specific recipient in an array of recipients.
dwRecipientEncryptedKeyIndex
Indicates a specific encrypted key in an array of encrypted keys.
OriginatorPublicKey
A CRYPT_BIT_BLOB structure that contains the sender's public key information.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows XP [desktop apps only] |
Minimum supported server | Windows Server 2003 [desktop apps only] |
Header | wincrypt.h |