Enable Extended Length command chaining by default

This commit is contained in:
c0de 2023-10-04 12:14:38 -05:00
parent d70ca4b185
commit 5168bb86d8
2 changed files with 4 additions and 14 deletions

View File

@ -1,13 +0,0 @@
diff --git a/src/dev/c0de/smartpgp/Constants.java b/src/dev/c0de/smartpgp/Constants.java
index b3c0f80..2ee1107 100644
--- a/src/dev/c0de/smartpgp/Constants.java
+++ b/src/dev/c0de/smartpgp/Constants.java
@@ -149,7 +149,7 @@ public final class Constants {
(byte)0x73, /* card capabilities */
(byte)0xC0, /* 1st byte: "methods supported" see ISO 7816-4 */
(byte)0x01, /* 2nd byte: "data coding byte" idem */
- (byte)0x80, /* 3rd byte: command chaining (not extended length by default as all readers do not support them...) */
+ (byte)0xC0, /* 3rd byte: command chaining + extended length */
(byte)0x05, /* status indicator byte : operational state */
(byte)0x90, /* SW1 */

View File

@ -148,7 +148,10 @@ public final class Constants {
(byte)0x73, /* card capabilities */ (byte)0x73, /* card capabilities */
(byte)0xC0, /* 1st byte: "methods supported" see ISO 7816-4 */ (byte)0xC0, /* 1st byte: "methods supported" see ISO 7816-4 */
(byte)0x01, /* 2nd byte: "data coding byte" idem */ (byte)0x01, /* 2nd byte: "data coding byte" idem */
(byte)0x80, /* 3rd byte: command chaining (not extended length by default as all readers do not support them...) */
/* 3rd byte: command chaining + extended length; Set to 0x80 if
extended length is not supported by card or reader */
(byte)0xC0,
(byte)0x05, /* status indicator byte : operational state */ (byte)0x05, /* status indicator byte : operational state */
(byte)0x90, /* SW1 */ (byte)0x90, /* SW1 */