Skip to content

Commit

Permalink
patch spurious select issue
Browse files Browse the repository at this point in the history
  • Loading branch information
Toporin committed Feb 8, 2024
1 parent 5716760 commit 1696682
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/org/seedkeeper/applet/SeedKeeper.java
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,9 @@ public class SeedKeeper extends javacard.framework.Applet {
* APPLET VERSION: changes with no impact on compatibility of the client
*/
// 0.1-0.1: initial version
// 0.2-0.1: WIP
private final static byte PROTOCOL_MAJOR_VERSION = (byte) 0;
private final static byte PROTOCOL_MINOR_VERSION = (byte) 1;
private final static byte PROTOCOL_MINOR_VERSION = (byte) 2;
private final static byte APPLET_MAJOR_VERSION = (byte) 0;
private final static byte APPLET_MINOR_VERSION = (byte) 1;

Expand Down Expand Up @@ -609,7 +610,8 @@ public void process(APDU apdu) {
byte[] buffer = apdu.getBuffer();
// check SELECT APDU command
if ((buffer[ISO7816.OFFSET_CLA] == 0) && (buffer[ISO7816.OFFSET_INS] == (byte) 0xA4))
return;
ISOException.throwIt(ISO7816.SW_FILE_NOT_FOUND); // spurious select (see https://github.com/Toporin/SatochipApplet/issues/11)

// verify the rest of commands have the
// correct CLA byte, which specifies the
// command structure
Expand Down

0 comments on commit 1696682

Please sign in to comment.