Re: Using OAEP/PSS RSA padding with CMS

2010-10-26 Thread Michael Orlov
 This is not currrently supported. The latest development releases
 include support for PSS in certificates and certificate requests but
 no OAEP/PSS support for CMS yet.
 
 Do you know of any examples using these modes?

I don't know of any such examples. I thought about using OpenSSL's CMS
functionality as a ready solution for message exchange between two
servers that have the same software, instead of directly using
dgst -sign / rand -base64 (session key) / enc / pkeyutl -encrypt (upon
sending a message) and pkeyutl -decrypt / enc -d / dgst -verify (upon
receiving a message). CMS also has the benefit of failing if
certificates don't verify against a trusted root CA, whereas failure
needs to be simulated for openssl verify.

But thinking about it, am I right that for CMS, the padding mechanism
doesn't really matter (as long as one is used), because
asymmetric keys are only used for signing a digest, and encrypting a
random session key? Which padding mechanism is used in CMS, the one
defined in PKCS 1.5?

Although, even if that is true, having OAEP/PSS in CMS would still be
nice, from cryptographic standards compliance point of view.

Thanks,
Michael
__
OpenSSL Project http://www.openssl.org
User Support Mailing Listopenssl-users@openssl.org
Automated List Manager   majord...@openssl.org


Using OAEP/PSS RSA padding with CMS

2010-10-23 Thread Michael Orlov
Hi,

What is the default RSA padding that is used in CMS when signing and
when encrypting messages?

Is there any way to influence the choice of padding in CMS? E.g., use
PSS for signing and OAEP for encryption when using RSA, as is possible
for dgst (sigopt) / pkeyutl (pkeyopt) with rsa_padding_mode:. I didn't
find any relevant command-line switches for that in cms.

By the way, the switch OAEP is rsa_padding_mode:oeap instead of oaep
(the man page for pkeyutl mentions both oeap and oaep).

Thanks,
Michael
__
OpenSSL Project http://www.openssl.org
User Support Mailing Listopenssl-users@openssl.org
Automated List Manager   majord...@openssl.org