diff options
Diffstat (limited to 'smcc/src')
-rw-r--r-- | smcc/src/main/java/at/gv/egiz/smcc/reader/CardReader.java | 14 | ||||
-rw-r--r-- | smcc/src/main/java/at/gv/egiz/smcc/reader/ReaderFactory.java | 10 |
2 files changed, 20 insertions, 4 deletions
diff --git a/smcc/src/main/java/at/gv/egiz/smcc/reader/CardReader.java b/smcc/src/main/java/at/gv/egiz/smcc/reader/CardReader.java index 6c5e939b..392f2fc2 100644 --- a/smcc/src/main/java/at/gv/egiz/smcc/reader/CardReader.java +++ b/smcc/src/main/java/at/gv/egiz/smcc/reader/CardReader.java @@ -55,7 +55,9 @@ public interface CardReader { "FEATURE_MODIFY_PIN_DIRECT_APP_ID", "FEATURE_WRITE_DISPLAY", "FEATURE_GET_KEY", - "FEATURE_IFD_DISPLAY_PROPERTIES"}; + "FEATURE_IFD_DISPLAY_PROPERTIES", + "FEATURE_GET_TLV_PROPERTIES", + "FEATURE_CCID_ESC_COMMAND"}; static final Byte FEATURE_VERIFY_PIN_START = new Byte((byte) 0x01); static final Byte FEATURE_VERIFY_PIN_FINISH = new Byte((byte) 0x02); @@ -67,7 +69,15 @@ public interface CardReader { static final Byte FEATURE_MCT_READER_DIRECT = new Byte((byte) 0x08); static final Byte FEATURE_MCT_UNIVERSAL = new Byte((byte) 0x09); static final Byte FEATURE_IFD_PIN_PROPERTIES = new Byte((byte) 0x0a); - //TODO continue list + static final Byte FEATURE_ABORT = new Byte((byte) 0x0b); + static final Byte FEATURE_SET_SPE_MESSAGE = new Byte((byte) 0x0c); + static final Byte FEATURE_VERIFY_PIN_DIRECT_APP_ID = new Byte((byte) 0x0d); + static final Byte FEATURE_MODIFY_PIN_DIRECT_APP_ID = new Byte((byte) 0x0e); + static final Byte FEATURE_WRITE_DISPLAY = new Byte((byte) 0x0f); + static final Byte FEATURE_GET_KEY = new Byte((byte) 0x10); + static final Byte FEATURE_IFD_DISPLAY_PROPERTIES = new Byte((byte) 0x11); + static final Byte FEATURE_GET_TLV_PROPERTIES = new Byte((byte) 0x12); + static final Byte FEATURE_CCID_ESC_COMMAND = new Byte((byte) 0x13); Card connect() throws CardException; diff --git a/smcc/src/main/java/at/gv/egiz/smcc/reader/ReaderFactory.java b/smcc/src/main/java/at/gv/egiz/smcc/reader/ReaderFactory.java index 0d0a8d8a..8ce98fcc 100644 --- a/smcc/src/main/java/at/gv/egiz/smcc/reader/ReaderFactory.java +++ b/smcc/src/main/java/at/gv/egiz/smcc/reader/ReaderFactory.java @@ -107,8 +107,14 @@ public class ReaderFactory { ((0xff & resp[i + 4]) << 8) | (0xff & resp[i + 5]); if (log.isInfoEnabled()) { - log.info("IFD supports {}: {}", CardReader.FEATURES[feature - .intValue()], Integer.toHexString(ioctl.intValue())); + if (feature.intValue() < CardReader.FEATURES.length) { + log.info("IFD supports {}: {}", CardReader.FEATURES[feature + .intValue()], Integer.toHexString(ioctl.intValue())); + } else { + log.info("IFD supports unknown feature 0x{}, : {}", Integer + .toHexString(feature), Integer + .toHexString(ioctl.intValue())); + } } features.put(feature, ioctl); } |