win32crypt.CryptSignAndEncryptMessage

str = CryptSignAndEncryptMessage(SignPara, EncryptPara , RecipientCert , ToBeSignedAndEncrypted )

Encrypts, encodes and signs a message using a certificate

Parameters

SignPara : PyCRYPT_SIGN_MESSAGE_PARA

Message signing parameters

EncryptPara : PyCRYPT_ENCRYPT_MESSAGE_PARA

Encryption parameters

RecipientCert : (PyCERT_CONTEXT,...)

Sequence of certificates of intended recipients

ToBeSignedAndEncrypted : str

Buffer containing data to be encoded in the message