INS 54h is also occupied too... let's try with 64h.

Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
Pol Henarejos 2022-04-08 00:38:03 +02:00
parent 4e6bada892
commit ce4d0bf102
No known key found for this signature in database
GPG key ID: C0095B7870A4CCD3
2 changed files with 11 additions and 11 deletions

View file

@ -4,12 +4,12 @@ Pico HSM supports a customized extra command to use with different options. Sinc
To send a raw APDU command, `opensc-tool -s <APDU>` can be used. The `APDU` parameter is a string of hexadecimal numbers and it takes the following form: To send a raw APDU command, `opensc-tool -s <APDU>` can be used. The `APDU` parameter is a string of hexadecimal numbers and it takes the following form:
``` ```
8054XX00YYZZZZRR 8064XX00YYZZZZRR
``` ```
It composed by the following fields: It composed by the following fields:
- `80` to indicate that it is a custom vendor type command. - `80` to indicate that it is a custom vendor type command.
- `54` is the `INS` custom command. - `64` is the `INS` custom command.
- `XX` is the command to execute. It varies depending on the targeted command. - `XX` is the command to execute. It varies depending on the targeted command.
- `00` is the parameter of the command. At this moment, no commands support parameters. - `00` is the parameter of the command. At this moment, no commands support parameters.
- `YY` is the length of the data. If no data is provided, this field is absent. - `YY` is the length of the data. If no data is provided, this field is absent.
@ -25,9 +25,9 @@ To obtain the current datetime (referenced to 00:00:00 2020/01/01), the `XX` par
For example, to obtain the current datetime: For example, to obtain the current datetime:
``` ```
$ opensc-tool -s 80540A0008 $ opensc-tool -s 80640A0008
Using reader with a card: Free Software Initiative of Japan Gnuk Using reader with a card: Free Software Initiative of Japan Gnuk
Sending: 80 54 0A 00 08 Sending: 80 64 0A 00 08
Received (SW1=0x90, SW2=0x00): Received (SW1=0x90, SW2=0x00):
07 E6 04 06 03 13 29 1E ......). 07 E6 04 06 03 13 29 1E ......).
``` ```
@ -47,9 +47,9 @@ If the command is correctly received, `SW1=0x90` and `SW2=0x00`. Other values me
To set the reference datetime, a datetime string must be provided. For example: To set the reference datetime, a datetime string must be provided. For example:
``` ```
$ opensc-tool -s 80540A000807E6040603132917 $ opensc-tool -s 80640A000807E6040603132917
Using reader with a card: Free Software Initiative of Japan Gnuk Using reader with a card: Free Software Initiative of Japan Gnuk
Sending: 80 54 0A 00 08 07 E6 04 06 03 13 29 17 Sending: 80 64 0A 00 08 07 E6 04 06 03 13 29 17
Received (SW1=0x90, SW2=0x00) Received (SW1=0x90, SW2=0x00)
``` ```
@ -66,9 +66,9 @@ Press-to-confirm button offers an extra security layer by requiring the user con
This feature is disabled by default but can be enabled rapidly by setting the LSB bit to 1: This feature is disabled by default but can be enabled rapidly by setting the LSB bit to 1:
``` ```
$ opensc-tool -s 805406000101 $ opensc-tool -s 806406000101
Using reader with a card: Free Software Initiative of Japan Gnuk Using reader with a card: Free Software Initiative of Japan Gnuk
Sending: 80 54 06 00 01 01 Sending: 80 64 06 00 01 01
Received (SW1=0x90, SW2=0x00) Received (SW1=0x90, SW2=0x00)
``` ```
@ -77,9 +77,9 @@ At this moment, when a private/secret key is loaded, the Pico HSM will wait for
To disable, the LSB bit must be set to 0: To disable, the LSB bit must be set to 0:
``` ```
$ opensc-tool -s 805406000100 $ opensc-tool -s 806406000100
Using reader with a card: Free Software Initiative of Japan Gnuk Using reader with a card: Free Software Initiative of Japan Gnuk
Sending: 80 54 06 00 01 00 Sending: 80 64 06 00 01 00
Received (SW1=0x90, SW2=0x00) Received (SW1=0x90, SW2=0x00)
``` ```

View file

@ -1812,9 +1812,9 @@ typedef struct cmd
#define INS_KEY_GEN 0x48 #define INS_KEY_GEN 0x48
#define INS_INITIALIZE 0x50 #define INS_INITIALIZE 0x50
#define INS_IMPORT_DKEK 0x52 #define INS_IMPORT_DKEK 0x52
#define INS_EXTRAS 0x54
#define INS_LIST_KEYS 0x58 #define INS_LIST_KEYS 0x58
#define INS_DECRYPT_ASYM 0x62 #define INS_DECRYPT_ASYM 0x62
#define INS_EXTRAS 0x64
#define INS_SIGNATURE 0x68 #define INS_SIGNATURE 0x68
#define INS_WRAP 0x72 #define INS_WRAP 0x72
#define INS_UNWRAP 0x74 #define INS_UNWRAP 0x74