mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-20 21:33:47 -07:00
4A emulation: warn if chaining command received
This commit is contained in:
parent
2efa4909f6
commit
4e5a8b9848
1 changed files with 5 additions and 2 deletions
|
@ -4050,7 +4050,7 @@ void SimulateIso14443aTagAID(uint8_t tagType, uint16_t flags, uint8_t *uid,
|
||||||
dynamic_response_info.response_n = 0;
|
dynamic_response_info.response_n = 0;
|
||||||
dynamic_response_info.modulation_n = 0;
|
dynamic_response_info.modulation_n = 0;
|
||||||
|
|
||||||
// Check for ISO 14443A-4 compliant commands, look at left nibble
|
// Check for ISO 14443A-4 compliant commands, look at left byte (PCB)
|
||||||
uint8_t offset = 0;
|
uint8_t offset = 0;
|
||||||
switch (receivedCmd[0]) {
|
switch (receivedCmd[0]) {
|
||||||
case 0x0B: // IBlock with CID
|
case 0x0B: // IBlock with CID
|
||||||
|
@ -4136,12 +4136,15 @@ void SimulateIso14443aTagAID(uint8_t tagType, uint16_t flags, uint8_t *uid,
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default: {
|
default: {
|
||||||
// Never seen this command before
|
// Never seen this PCB before
|
||||||
LogTrace(receivedCmd, Uart.len, Uart.startTime * 16 - DELAY_AIR2ARM_AS_TAG, Uart.endTime * 16 - DELAY_AIR2ARM_AS_TAG, Uart.parity, true);
|
LogTrace(receivedCmd, Uart.len, Uart.startTime * 16 - DELAY_AIR2ARM_AS_TAG, Uart.endTime * 16 - DELAY_AIR2ARM_AS_TAG, Uart.parity, true);
|
||||||
if (g_dbglevel >= DBG_DEBUG) {
|
if (g_dbglevel >= DBG_DEBUG) {
|
||||||
Dbprintf("Received unknown command (len=%d):", len);
|
Dbprintf("Received unknown command (len=%d):", len);
|
||||||
Dbhexdump(len, receivedCmd, false);
|
Dbhexdump(len, receivedCmd, false);
|
||||||
}
|
}
|
||||||
|
if ((receivedCmd[0] & 0x10) == 0x10) {
|
||||||
|
Dbprintf("Warning, reader sent a chained command but we lack support for it. Ignoring command.");
|
||||||
|
}
|
||||||
// Do not respond
|
// Do not respond
|
||||||
dynamic_response_info.response_n = 0;
|
dynamic_response_info.response_n = 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue