The following are APDUs I send and receive. For second command, I got 6444.
>>00a4040009a0000000620301080100
<<9000
>>80b800000b09a0000004e0000100010000
<<6444
I debugged my applet step by step, finally I found where the problem exists. But I still don't know how to fix this problem. Hope somebody give me some pointers.
The code that has problems.
Code: Select all
privateCrtKey = (RSAPrivateCrtKey)KeyBuilder.buildKey(KeyBuilder.TYPE_RSA_CRT_PRIVATE, KeyBuilder.LENGTH_RSA_2048, false);
asymSignature = Signature.getInstance(Signature.ALG_RSA_SHA_PKCS1, false);