status-im / keycard-cli

A command line tool and shell to manage keycards
https://keycard.tech
Mozilla Public License 2.0
46 stars 17 forks source link

Unable to install Keycard Apple on NXP J3R180 Java card #18

Open RadRutvi opened 1 year ago

RadRutvi commented 1 year ago

rutvishah@Rutvis-Laptop keycard % ./keycard install -l debug -a keycard.cap -f INFO [07-10|17:44:25.562] waiting for a card package=status-go/cmd/keycard INFO [07-10|17:44:25.565] card found package=status-go/cmd/keycard index=0 DEBUG[07-10|17:44:25.565] using reader package=status-go/cmd/keycard name="SCM Microsystems Inc. SCR 3310" DEBUG[07-10|17:44:25.565] connecting to card package=status-go/cmd/keycard reader="SCM Microsystems Inc. SCR 3310" DEBUG[07-10|17:44:25.565] card protocol package=status-go/cmd/keycard T=1 INFO [07-10|17:44:25.566] installation started package=status-go/cmd/keycard INFO [07-10|17:44:25.566] check if keycard is already installed package=status-go/cmd/keycard DEBUG[07-10|17:44:25.566] apdu command package=io hex="00 A4 04 00 09 A0 00 00 08 04 00 01 01 01 00" DEBUG[07-10|17:44:25.579] apdu response package=io hex="6A 82" INFO [07-10|17:44:25.579] select ISD package=status-go/cmd/keycard DEBUG[07-10|17:44:25.579] apdu command package=io hex="00 A4 04 00 00" DEBUG[07-10|17:44:25.595] apdu response package=io hex="6F 10 84 08 A0 00 00 01 51 00 00 00 A5 04 9F 65 01 FF 90 00" INFO [07-10|17:44:25.595] opening secure channel package=status-go/cmd/keycard DEBUG[07-10|17:44:25.596] apdu command package=io hex="80 50 00 00 08 A9 73 FA 95 E6 AC 10 97 00" DEBUG[07-10|17:44:25.656] apdu response package=io hex="00 00 23 45 56 41 81 20 48 39 01 03 10 71 E4 AF 02 AB 6E 19 2C 42 02 70 69 C6 E8 E7 75 00 00 04 90 00" DEBUG[07-10|17:44:25.656] initialize session package=keycard/globalplatform keys=keycard ERROR[07-10|17:44:25.656] open secure channel failed package=status-go/cmd/keycard error="bad response 9000: bad data length, expected 28, got 32" ERROR[07-10|17:44:25.656] error executing command package=status-go/cmd/keycard command=install error="bad response 9000: bad data length, expected 28, got 32"

bitgamma commented 1 year ago

It it a problem with opening the secure channel. I will check what's the issue. In the meantime, you can try to install the applet using https://github.com/martinpaljak/GlobalPlatformPro or any other similar tool