Here is how one should sign a message with openssl smime? according to the docs

openssl smime -sign -in in.txt -text -out mail.msg -signer mycert.pem \
 -inkey mykey.pem -certfile mycerts.pem

But why is there a -signer key with a certificate -- isn't a private key passed in -inkey enough for message signing? Isn't it just a usual asymmetric encryption scheme, where my private key is for message signing and my certificate (i.e., signed public key corresponding to my private key) is for my counterpart to encrypt the message?


As far as I found out this is for the second side to verify your signature -- in case if it does not have that certificate.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.