CryptSIPPutSignedDataMsg function
[The CryptSIPPutSignedDataMsg function is available for use in the operating systems specified in the Requirements section. It may be altered or unavailable in subsequent versions.]
Applies to: desktop apps only
The CryptSIPPutSignedDataMsg function stores an Authenticode signature in the target file.
Syntax
BOOL WINAPI CryptSIPPutSignedDataMsg( __in SIP_SUBJECTINFO *pSubjectInfo, __in DWORD dwEncodingType, __out DWORD *pdwIndex, __in DWORD cbSignedDataMsg, __in BYTE *pbSignedDataMsg );
Parameters
- pSubjectInfo [in]
-
Pointer to a SIP_SUBJECTINFO structure that contains information about the message subject.
- dwEncodingType [in]
-
The encoding type of the message. This can be a combination of one or more of the following values.
Value Meaning - PKCS_7_ASN_ENCODING
- 65536 (0x10000)
Specifies PKCS #7 message encoding.
- X509_ASN_ENCODING
- 1 (0x1)
Specifies X.509 certificate encoding.
- pdwIndex [out]
-
Pointer to the message index.
- cbSignedDataMsg [in]
-
Length, in bytes, of the buffer pointed to by the pbSignedDataMsg parameter.
- pbSignedDataMsg [in]
-
Pointer to the buffer that contains the message.
Return value
If the function succeeds, the function returns TRUE.
If the function fails, it returns FALSE. For extended error information, call GetLastError. Some possible error codes follow.
| Return code | Description |
|---|---|
|
The specified data or file format of the subject interface package (SIP) is not valid. |
|
This code can be returned for the following reasons:
|
|
The specified subject type is not valid. |
Remarks
Each subject type uses a different subset of its data for hash calculation and requires a different procedure for storage and retrieval. Therefore, each subject type has a unique SIP specification.
Requirements
|
Minimum supported client | Windows 2000 Professional |
|---|---|
|
Minimum supported server | Windows 2000 Server |
|
Header |
|
|
Library |
|
|
DLL |
|
See also
Send comments about this topic to Microsoft
Build date: 3/6/2012