- if(!iso14443a_select_card(uid, NULL, &cuid, true, 0)) {\r
+ if(!iso14443a_select_card(uid, NULL, &cuid, true, 0)) {\r
cmd_send(CMD_ACK,isOK,0,0,0,0);\r
cmd_send(CMD_ACK,isOK,0,0,0,0);\r
// Mifare Classic Cards" in Proceedings of the 22nd ACM SIGSAC Conference on \r
// Computer and Communications Security, 2015\r
//-----------------------------------------------------------------------------\r
// Mifare Classic Cards" in Proceedings of the 22nd ACM SIGSAC Conference on \r
// Computer and Communications Security, 2015\r
//-----------------------------------------------------------------------------\r
#define PRE_AUTHENTICATION_LEADTIME 400 // some (non standard) cards need a pause after select before they are ready for first authentication \r
\r
void MifareAcquireEncryptedNonces(uint32_t arg0, uint32_t arg1, uint32_t flags, uint8_t *datain)\r
#define PRE_AUTHENTICATION_LEADTIME 400 // some (non standard) cards need a pause after select before they are ready for first authentication \r
\r
void MifareAcquireEncryptedNonces(uint32_t arg0, uint32_t arg1, uint32_t flags, uint8_t *datain)\r
memcpy(buf+i, receivedAnswer, 4);\r
nt_par_enc = par_enc[0] & 0xf0;\r
} else {\r
memcpy(buf+i, receivedAnswer, 4);\r
nt_par_enc = par_enc[0] & 0xf0;\r
} else {\r
memcpy(buf+i+4, receivedAnswer, 4);\r
memcpy(buf+i+8, &nt_par_enc, 1);\r
i += 9;\r
memcpy(buf+i+4, receivedAnswer, 4);\r
memcpy(buf+i+8, &nt_par_enc, 1);\r
i += 9;\r
LED_B_ON();\r
cmd_send(CMD_ACK, isOK, cuid, num_nonces, buf, sizeof(buf));\r
LED_B_OFF();\r
LED_B_ON();\r
cmd_send(CMD_ACK, isOK, cuid, num_nonces, buf, sizeof(buf));\r
LED_B_OFF();\r
if(!iso14443a_select_card(uid, NULL, &cuid, true, 0)) {\r
if (MF_DBGLEVEL >= MF_DBG_ERROR) Dbprintf("Can't select card");\r
errormsg = MAGIC_UID;\r
if(!iso14443a_select_card(uid, NULL, &cuid, true, 0)) {\r
if (MF_DBGLEVEL >= MF_DBG_ERROR) Dbprintf("Can't select card");\r
errormsg = MAGIC_UID;\r