Closed dschuermann closed 5 years ago
I found a card to test this issue, and I found the problem.
The check
method from the OwnerPIN
card does not decrement the retry counter if the length of the PIN given in parameter is zero, which generates an infinite loop during install on this card.
Commit https://github.com/ANSSI-FR/SmartPGP/commit/9637be6035b1b2e94daec1e2b5195678c03e7d54 solves this issue on my sample card.
Can you confirm it is OK on yours too ?
Great this works now! Thanks for debugging!
We are trying to install the 3.0.1 version of SmartPGP applet (compiled with ant from https://github.com/ANSSI-FR/SmartPGP/tree/javacard-3.0.1) onto a NXP J3D081 DI card using gp version 18.08.16.1 with
java -jar gp.jar -install SmartPGPApplet301-ant.cap -default -d -v -i
. The installation process stops at a point and the card no longer answers. After re-inserting the card, the applet is loaded but it is not working, i.e., it does not answer ongpg --card-edit
This problem has first been posted to https://github.com/martinpaljak/GlobalPlatformPro/issues/134 but it looks like this is a problem of SmartPGP itself.
After reinserting:
gpg: