mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-19 13:00:42 -07:00
Change 'hf 14a list' to annotate more ECP frame formats
This commit is contained in:
parent
a0ac404497
commit
b11b4e66af
3 changed files with 14 additions and 3 deletions
|
@ -3,6 +3,7 @@ All notable changes to this project will be documented in this file.
|
|||
This project uses the changelog in accordance with [keepchangelog](http://keepachangelog.com/). Please use this to write notable changes, which is not the same as git commit log...
|
||||
|
||||
## [unreleased][unreleased]
|
||||
- Change `trace list -t 14a` to annotate ECP frames of all valid V1 and V2 formats (@kormax)
|
||||
- Changed `hf mf staticnested` - significant speedups by using two encrypted nonces (@xianglin1998)
|
||||
- Change use of `sprintf` in code to `snprintf` to fix compilation on macOS (@Doridian)
|
||||
- Change `hf mf mad` - it now takes a dump file for offline MAD decoding (@iceman1001)
|
||||
|
|
|
@ -181,9 +181,17 @@ int applyIso14443a(char *exp, size_t size, uint8_t *cmd, uint8_t cmdsize, bool i
|
|||
return PM3_SUCCESS;
|
||||
}
|
||||
|
||||
if (cmdsize > 10 && (memcmp(cmd, "\x6a\x02\xC8\x01\x00\x03\x00\x02\x79", 9) == 0)) {
|
||||
snprintf(exp, size, "ECP");
|
||||
if (cmdsize >= 7 && cmd[0] == ECP_HEADER) {
|
||||
// Second byte of ECP frame indicates its version
|
||||
// Version 0x01 payload is 7 bytes long (including crc)
|
||||
// Version 0x02 payload is 15 bytes long (including crc)
|
||||
if (cmd[1] == 0x01 && cmdsize == 7) {
|
||||
snprintf(exp, size, "ECP1");
|
||||
return PM3_SUCCESS;
|
||||
} else if (cmd[1] == 0x02 && cmdsize == 15) {
|
||||
snprintf(exp, size, "ECP2");
|
||||
return PM3_SUCCESS;
|
||||
}
|
||||
}
|
||||
|
||||
gs_ntag_i2c_state = 0;
|
||||
|
|
|
@ -158,6 +158,8 @@ ISO 7816-4 Basic interindustry commands. For command APDU's.
|
|||
#define ICLASS_DEBIT(x) (((x) & 0x80) == 0x80)
|
||||
|
||||
|
||||
#define ECP_HEADER 0x6A
|
||||
|
||||
// 7bit Apple Magsafe wake up command
|
||||
#define MAGSAFE_CMD_WUPA_1 0x7A
|
||||
#define MAGSAFE_CMD_WUPA_2 0x7B
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue