We are trying to automate certain processes with Chilkat.
In particular we are trying to generate a PKCS7 document that contains the following features:
- A signed xml document. This signing is done via smartcard and the output must include the signature. For this point, we are using the crypt2 object with :
- EncodingMode, HashAlgorithm and charset attributes
- SetSigningCert, OpaqueSignStringENC methods
- We need also to include the signer's digital signature certificate in X.509 ASN encoding. This second point is where we are having some problems.
We have obtained a valid signed document according to the 2 points through the createp7m method for manual testing but the point of our program is to automate the process in memory. Therefore, we are trying to use the OpaqueSignStringENC("original xml to sign") but we believe the point (2) is not being taken into account.
I don't know if anyone has encountered a similar problem. I just recently started working with encryption, certificates...sorry if I am explaining myself incorrectly.
Thanks everyone for your help and time