crypt32: Implement retrieving the encoded signer of a decoded signed message.
This commit is contained in:
parent
addf0c11a0
commit
96be0ee8dc
|
@ -2410,6 +2410,20 @@ static BOOL CDecodeSignedMsg_GetParam(CDecodeMsg *msg, DWORD dwParamType,
|
|||
else
|
||||
SetLastError(CRYPT_E_INVALID_MSG_TYPE);
|
||||
break;
|
||||
case CMSG_ENCODED_SIGNER:
|
||||
if (msg->u.signed_data.info)
|
||||
{
|
||||
if (dwIndex >= msg->u.signed_data.info->cSignerInfo)
|
||||
SetLastError(CRYPT_E_INVALID_INDEX);
|
||||
else
|
||||
ret = CryptEncodeObjectEx(
|
||||
X509_ASN_ENCODING | PKCS_7_ASN_ENCODING, CMS_SIGNER_INFO,
|
||||
&msg->u.signed_data.info->rgSignerInfo[dwIndex], 0, NULL,
|
||||
pvData, pcbData);
|
||||
}
|
||||
else
|
||||
SetLastError(CRYPT_E_INVALID_MSG_TYPE);
|
||||
break;
|
||||
case CMSG_ATTR_CERT_COUNT_PARAM:
|
||||
if (msg->u.signed_data.info)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue