make style

This commit is contained in:
nvx 2023-08-24 15:18:39 +10:00
commit 8dd963d305
11 changed files with 471 additions and 459 deletions

View file

@ -222,9 +222,12 @@ static void become_card(void) {
static void prepare_emulation(uint8_t *tagType, uint16_t *flags, uint8_t *data, packet_t *ats) {
packet_t tagTypeRx = { 0 }; read_packet(&tagTypeRx);
packet_t timeModeRx = { 0 }; read_packet(&timeModeRx);
packet_t uidRx = { 0 }; read_packet(&uidRx);
packet_t tagTypeRx = { 0 };
read_packet(&tagTypeRx);
packet_t timeModeRx = { 0 };
read_packet(&timeModeRx);
packet_t uidRx = { 0 };
read_packet(&uidRx);
read_packet(ats);
*tagType = tagTypeRx.dat[0];
@ -269,13 +272,19 @@ static void cook_ats(packet_t *ats, uint8_t fwi, uint8_t sfgi) {
// Might be better for the phone side to do this tbh
if (ats->len == 1) {
ats->len = 4;
ats->dat[0] = 0x04; ats->dat[1] = 0x78; ats->dat[2] = 0x77; ats->dat[3] = 0x80;
ats->dat[0] = 0x04;
ats->dat[1] = 0x78;
ats->dat[2] = 0x77;
ats->dat[3] = 0x80;
} else if (ats->len == 2) {
ats->len = 4;
ats->dat[0] = 0x04; ats->dat[2] = 0x77; ats->dat[3] = 0x80;
ats->dat[0] = 0x04;
ats->dat[2] = 0x77;
ats->dat[3] = 0x80;
} else if (ats->len == 3) {
ats->len = 4;
ats->dat[0] = 0x04; ats->dat[3] = 0x80;
ats->dat[0] = 0x04;
ats->dat[3] = 0x80;
}
// Set the SFGI as well as the FWI - needed for some older readers (firmware revs?)

View file

@ -3397,13 +3397,16 @@
"description": "Print a iCLASS tag dump file (bin/eml/json)",
"notes": [
"hf iclass view -f hf-iclass-AA162D30F8FF12F1-dump.bin",
"hf iclass view --first 1 -f hf-iclass-AA162D30F8FF12F1-dump.bin"
"hf iclass view --first 1 -f hf-iclass-AA162D30F8FF12F1-dump.bin",
"",
"If --first is not specified it will default to the first user block",
"which is block 6 for secured chips or block 3 for non-secured chips"
],
"offline": true,
"options": [
"-h, --help This help",
"-f, --file <fn> filename of dump (bin/eml/json)",
"--first <dec> Begin printing from this block (default first user block - 6 or 3 on non secured chips)",
"--first <dec> Begin printing from this block (default first user block)",
"--last <dec> End printing at this block (default 0, ALL)",
"-v, --verbose verbose output",
"-z, --dense dense dump output style"
@ -11834,6 +11837,6 @@
"metadata": {
"commands_extracted": 686,
"extracted_by": "PM3Help2JSON v1.00",
"extracted_on": "2023-08-22T23:15:58"
"extracted_on": "2023-08-24T05:14:06"
}
}