From: merlokk Date: Wed, 17 Jan 2018 13:48:01 +0000 (+0200) Subject: SNF_WUPREQ and SNF_SAK harmonized) X-Git-Tag: v3.1.0~84^2~4 X-Git-Url: https://git.zerfleddert.de/cgi-bin/gitweb.cgi/proxmark3-svn/commitdiff_plain/543a6ed3c99fb1f1324b25d7d2132133dce904dc?ds=sidebyside;hp=968cb35498c6d6331a4c65b1f23dad2bbeb79f6f SNF_WUPREQ and SNF_SAK harmonized) --- diff --git a/armsrc/mifaresniff.c b/armsrc/mifaresniff.c index f4879329..3929561e 100644 --- a/armsrc/mifaresniff.c +++ b/armsrc/mifaresniff.c @@ -59,25 +59,22 @@ bool RAMFUNC MfSniffLogic(const uint8_t *data, uint16_t len, uint8_t *parity, ui memset(sniffUID, 0x00, 8); memset(sniffATQA, 0x00, 2); sniffSAK = 0; - sniffState = SNF_WUPREQ; + sniffState = SNF_ATQA; } break; } - case SNF_WUPREQ:{ + case SNF_ATQA:{ if ((!reader) && (len == 2)) { // ATQA from tag memcpy(sniffATQA, data, 2); - sniffState = SNF_ATQA; + sniffState = SNF_UID1; } break; } - case SNF_ATQA: case SNF_UID1:{ - // SNF_ATQA if ((reader) && (len == 2) && (data[0] == 0x93) && (data[1] == 0x20)) { // Select ALL from reader sniffState = SNF_ANTICOL1; } - // SNF_UID1 if ((reader) && (len == 9) && (data[0] == 0x93) && (data[1] == 0x70) && (CheckCrc14443(CRC_14443_A, data, 9))) { // Select 4 Byte UID from reader memcpy(sniffUID + 3, &data[2], 4); sniffState = SNF_SAK;