mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2026-05-12 11:18:11 -07:00
Merge pull request #3274 from gentilkiwi/patch-1
Update mifaredesfire.c to support DESELECT response
This commit is contained in:
+10
-2
@@ -756,11 +756,19 @@ size_t CreateAPDU(uint8_t *datain, size_t len, uint8_t *dataout) {
|
||||
// uint32_t crc = crc_finish(&desfire_crc32);
|
||||
|
||||
void OnSuccess(void) {
|
||||
size_t len = 0;
|
||||
uint8_t resp[MAX_FRAME_SIZE];
|
||||
uint8_t par[MAX_PARITY_SIZE];
|
||||
|
||||
pcb_blocknum = 0;
|
||||
ReaderTransmit(deselect_cmd, 3, NULL);
|
||||
if (mifare_ultra_halt()) {
|
||||
if (g_dbglevel >= DBG_ERROR) Dbprintf("Halt error");
|
||||
len = ReaderReceive(resp, sizeof(resp), par);
|
||||
if (len == 0) {
|
||||
if (mifare_ultra_halt()) {
|
||||
if (g_dbglevel >= DBG_ERROR) Dbprintf("Halt error");
|
||||
}
|
||||
}
|
||||
|
||||
switch_off();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user