mirror of
https://github.com/Proxmark/proxmark3.git
synced 2025-08-14 10:36:58 -07:00
CHG: minor code clean up in ArmSrc.
ADD: added some more default keys in Hf mf nested, maybe it runs faster :)
This commit is contained in:
parent
79bf1ad2cc
commit
787b5bd8a4
6 changed files with 150 additions and 115 deletions
|
@ -513,7 +513,6 @@ int CmdHF14AMfDump(const char *Cmd)
|
|||
}
|
||||
|
||||
fclose(fin);
|
||||
// Read access rights to sectors
|
||||
|
||||
PrintAndLog("|-----------------------------------------|");
|
||||
PrintAndLog("|------ Reading sector access bits...-----|");
|
||||
|
@ -544,8 +543,6 @@ int CmdHF14AMfDump(const char *Cmd)
|
|||
}
|
||||
}
|
||||
|
||||
// Read blocks and print to file
|
||||
|
||||
PrintAndLog("|-----------------------------------------|");
|
||||
PrintAndLog("|----- Dumping all blocks to file... -----|");
|
||||
PrintAndLog("|-----------------------------------------|");
|
||||
|
@ -739,7 +736,7 @@ int CmdHF14AMfNested(const char *Cmd)
|
|||
uint8_t trgKeyType = 0;
|
||||
uint8_t SectorsCnt = 0;
|
||||
uint8_t key[6] = {0, 0, 0, 0, 0, 0};
|
||||
uint8_t keyBlock[6*6];
|
||||
uint8_t keyBlock[13*6];
|
||||
uint64_t key64 = 0;
|
||||
bool transferToEml = false;
|
||||
|
||||
|
@ -856,6 +853,14 @@ int CmdHF14AMfNested(const char *Cmd)
|
|||
num_to_bytes(0xa0a1a2a3a4a5, 6, (uint8_t*)(keyBlock + 3 * 6));
|
||||
num_to_bytes(0xb0b1b2b3b4b5, 6, (uint8_t*)(keyBlock + 4 * 6));
|
||||
num_to_bytes(0xaabbccddeeff, 6, (uint8_t*)(keyBlock + 5 * 6));
|
||||
num_to_bytes(0x4d3a99c351dd, 6, (uint8_t*)(keyBlock + 6 * 6));
|
||||
num_to_bytes(0x1a982c7e459a, 6, (uint8_t*)(keyBlock + 7 * 6));
|
||||
num_to_bytes(0xd3f7d3f7d3f7, 6, (uint8_t*)(keyBlock + 8 * 6));
|
||||
num_to_bytes(0x714c5c886e97, 6, (uint8_t*)(keyBlock + 9 * 6));
|
||||
num_to_bytes(0x587ee5f9350f, 6, (uint8_t*)(keyBlock + 10 * 6));
|
||||
num_to_bytes(0xa0478cc39091, 6, (uint8_t*)(keyBlock + 11 * 6));
|
||||
num_to_bytes(0x533cb6c723f6, 6, (uint8_t*)(keyBlock + 12 * 6));
|
||||
num_to_bytes(0x8fd0a4f256e9, 6, (uint8_t*)(keyBlock + 13 * 6));
|
||||
|
||||
PrintAndLog("Testing known keys. Sector count=%d", SectorsCnt);
|
||||
for (i = 0; i < SectorsCnt; i++) {
|
||||
|
@ -883,8 +888,7 @@ int CmdHF14AMfNested(const char *Cmd)
|
|||
if(mfnested(blockNo, keyType, key, FirstBlockOfSector(sectorNo), trgKeyType, keyBlock, calibrate)) {
|
||||
PrintAndLog("Nested error.\n");
|
||||
free(e_sector);
|
||||
return 2;
|
||||
}
|
||||
return 2; }
|
||||
else {
|
||||
calibrate = false;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue