Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
New Contributor I
6 Views

Cryptography: RSA key validation

Hello
In the example from IPP Reference Manual, Vol 4: Cryptography, p. 390
one can find the line:

ippsRSAValidate(E, 50, &result, pRSAprv2, ippsPRNGen, pRand);

which validates the RSA key pRSAprv2 (CRT version).
In that case the validation is OK.

My problem is:
When I try to validate the pRSAprv1 key (no-CRT version)
which is also set in the same code, ie.
when I replace the previous validation by:

ippsRSAValidate(E, 50, &result, pRSAprv1, ippsPRNGen, pRand);

then the validation fails.

Can somebody clarify the difference.
Does the validation function accept the no-CRT version of RSA keys?

Andrzej Ch.
0 Kudos
2 Replies
Highlighted
Employee
6 Views

Hi Andrzej,

ippsRSAValidate only validates pRSAprv2 ( (E,P,Q,D) data).

pRSAprv1 ((E,N,D) data) is unlike pRSAprv2. It can not be validated by some mathematics.

Thanks,

Chao

0 Kudos
Highlighted
New Contributor I
6 Views

Hi Chao
Thank you for replay

I have two remarks

1. I think, the function RSAValidate should not return:

ippStsNoErr: No error, it's OK

when the appropriate P,Q are not set (and the validation fails-
-the case of pRSAprv1)

2. I think that the user should be warned (for example in the manual)
that if she/he sets the private key as the pair N,D, then the
validation is impossible

3. I can understand the present approach (for its efficiency)
(from purely mathematical point of view, the person who knows D
has to know P,Q but one can cipher without setting these parameters)

Andrzej Ch.
0 Kudos