RE: Encrypting and signing data
From: lelteto (lelteto_at_discussions.microsoft.com)
Date: Wed, 13 Apr 2005 08:43:25 -0700
Certainly it is possible to use low-level CAPI functions to separately create
signature (CryptCreateHash, CryptHashData, CryptSignHasn) and encrypt your
> I am looking to create my own encrypted file format. By
> this I mean the order in which the encrypted session key,
> signature and data are stored.
> So rather than using CryptSignAndEncryptMessage, using
> certificates, is it possible to separately sign and
> separately encrypt the data (and reverse this operation)?
> One issue I am worried about is to retreive the public key
> from the certificate when encrypting. I don't know of any
> function to get the public key from the certificate.