fix: 'hf iclass clone' - last block write fails, see (https://github.com/RfidResearchGroup/proxmark3/issues/183)

chg: 'hf iclass clone' - now tries ten times,  behavies better, obey verbose nicer, drop field constant. Uses NG.
chg: 'hf iclass dump' - now tries ten times,
in general nice outputs..
This commit is contained in:
iceman1001 2019-09-08 23:19:06 +02:00
commit 9a2a0116e4
3 changed files with 145 additions and 87 deletions

View file

@ -1271,7 +1271,13 @@ static void PacketReceived(PacketCommandNG *packet) {
break;
}
case CMD_HF_ICLASS_CLONE: {
iClass_Clone(packet->oldarg[0], packet->oldarg[1], packet->data.asBytes);
struct p {
uint8_t startblock;
uint8_t endblock;
uint8_t data[];
} PACKED;
struct p *payload = (struct p *)packet->data.asBytes;
iClass_Clone(payload->startblock, payload->endblock, payload->data);
break;
}
#endif