JavacardOS will not accept order any more, please contact our partner Feitian online Store:
https://ftsafe.en.alibaba.com/index.html

generate RSA public and private key

JavaCard Applet Development Related Questions and Answers.
Tazmania09
Posts: 25
Joined: Mon Nov 30, 2015 3:40 am
Points :178
Contact:

generate RSA public and private key

Post by Tazmania09 » Wed Jun 22, 2016 11:19 pm

When I generated RSA public and private key by KeyPair(KeyPair.ALG_RSA, KeyBuilder.LENGTH_RSA_1024) , I got 6F 00.

But when I used KeyPair(KeyPair.ALG_RSA_CRT, KeyBuilder.LENGTH_RSA_1024) , it can be successfull. I have no idea about why this happened. Hope anyone help me find the reason. Thanks a lot

corleoner
Posts: 15
Joined: Fri Dec 11, 2015 2:22 am
Points :92
Contact:

Re: generate RSA public and private key

Post by corleoner » Thu Jun 23, 2016 6:10 am

The reason that you got 6F 00 is because there is un-handled exception in your code. Use try/catch statements to catch exception and find out exception reason.

Moreover, it turns out that ALG_RSA_CRT is the same as ALG_RSA, so if there is something wrong with ALG_RSA, just use ALG_RSA_CRT.

rena2019
Posts: 68
Joined: Thu Aug 20, 2015 4:16 pm
Points :1790
Contact:

Re: generate RSA public and private key

Post by rena2019 » Thu Jun 23, 2016 3:20 pm

corleoner wrote:Moreover, it turns out that ALG_RSA_CRT is the same as ALG_RSA, so if there is something wrong with ALG_RSA, just use ALG_RSA_CRT.
what? ALG_RSA_CRT is the same as ALG_RSA?

corleoner
Posts: 15
Joined: Fri Dec 11, 2015 2:22 am
Points :92
Contact:

Re: generate RSA public and private key

Post by corleoner » Thu Jun 23, 2016 9:46 pm

rena2019 wrote:
corleoner wrote:Moreover, it turns out that ALG_RSA_CRT is the same as ALG_RSA, so if there is something wrong with ALG_RSA, just use ALG_RSA_CRT.
what? ALG_RSA_CRT is the same as ALG_RSA?


Well.. Isn't that so? If I said something wrong or misunderstood something, please correct me. thanks

Post Reply Previous topicNext topic

Who is online

Users browsing this forum: No registered users and 46 guests

JavaCard OS : Disclaimer