fix: 'sc list' - the iso7816-4 annotation now prints.
This commit is contained in:
@@ -326,8 +326,19 @@ void annotateIso7816(char *exp, size_t size, uint8_t* cmd, uint8_t cmdsize){
|
|||||||
}
|
}
|
||||||
// I-block
|
// I-block
|
||||||
else {
|
else {
|
||||||
|
int pos = 0;
|
||||||
int pos = (cmd[0] == 2 || cmd[0] == 3) ? 2 : 3;
|
switch ( cmd[0] ) {
|
||||||
|
case 2:
|
||||||
|
case 3:
|
||||||
|
pos = 2;
|
||||||
|
break;
|
||||||
|
case 0:
|
||||||
|
pos = 1;
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
pos = 3;
|
||||||
|
break;
|
||||||
|
}
|
||||||
switch ( cmd[pos] ){
|
switch ( cmd[pos] ){
|
||||||
case ISO7816_READ_BINARY :snprintf(exp, size, "READ BIN");break;
|
case ISO7816_READ_BINARY :snprintf(exp, size, "READ BIN");break;
|
||||||
case ISO7816_WRITE_BINARY :snprintf(exp, size, "WRITE BIN");break;
|
case ISO7816_WRITE_BINARY :snprintf(exp, size, "WRITE BIN");break;
|
||||||
|
|||||||
@@ -174,6 +174,7 @@ uint16_t printTraceLine(uint16_t tracepos, uint16_t traceLen, uint8_t *trace, ui
|
|||||||
case ISO_15693:
|
case ISO_15693:
|
||||||
crcStatus = iso15693_CRC_check(frame, data_len);
|
crcStatus = iso15693_CRC_check(frame, data_len);
|
||||||
break;
|
break;
|
||||||
|
case ISO_7816_4:
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@@ -527,6 +528,8 @@ int CmdTraceList(const char *Cmd) {
|
|||||||
PrintAndLogEx(NORMAL, "ISO15693 - Timings are not as accurate");
|
PrintAndLogEx(NORMAL, "ISO15693 - Timings are not as accurate");
|
||||||
if ( protocol == FELICA )
|
if ( protocol == FELICA )
|
||||||
PrintAndLogEx(NORMAL, "ISO18092 / FeliCa - Timings are not as accurate");
|
PrintAndLogEx(NORMAL, "ISO18092 / FeliCa - Timings are not as accurate");
|
||||||
|
if ( protocol == ISO_7816_4 )
|
||||||
|
PrintAndLogEx(NORMAL, "ISO7816-4 / Smartcard - Timings N/A yet");
|
||||||
|
|
||||||
PrintAndLogEx(NORMAL, "");
|
PrintAndLogEx(NORMAL, "");
|
||||||
PrintAndLogEx(NORMAL, " Start | End | Src | Data (! denotes parity error) | CRC | Annotation");
|
PrintAndLogEx(NORMAL, " Start | End | Src | Data (! denotes parity error) | CRC | Annotation");
|
||||||
|
|||||||
Reference in New Issue
Block a user