[Softhsm-develop] CK_RSA_PKCS_OAEP_PARAMS.source question

Rickard Bellgrim rickard at opendnssec.org
Sun Sep 28 19:33:13 UTC 2014

On Wed, Sep 24, 2014 at 2:20 PM, Petr Spacek <pspacek at redhat.com> wrote:

> Hello,
> I'm working on a patch with PKCS #1 RSA OAEP support and I have a question
> regarding "source" member in CK_RSA_PKCS_OAEP_PARAMS structure.
> IMHO CK_RSA_PKCS_OAEP_PARAMS.source should always be set to
> CKZ_DATA_SPECIFIED, i.e. to 0x00000001.
> Is this correct (I'm looking into pkcs-11v2-30m1-d7.doc page 26)?
> I'm asking because current code ignores this value completely so I'm
> trying to determine if it is a bug or intentional decision.
> Thank you for clarification!

Yes, that is correct. I believe that this field was not checked because the
parameter is not used by the function. If we want to be strict then source
== CKZ_DATA_SPECIFIED, pSourceData == NULL_PTR, and ulSourceDataLen == 0
must be set.

 // Rickard
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opendnssec.org/pipermail/softhsm-develop/attachments/20140928/11e5ecbf/attachment.htm>

More information about the Softhsm-develop mailing list