fix typo + missing free()

This commit is contained in:
PhaseLoop 2024-01-16 21:14:40 +00:00
commit fe5691997d
2 changed files with 9 additions and 1 deletions

View file

@ -2338,7 +2338,7 @@ EA0CA627FD06
CE0F4F15E909 CE0F4F15E909
D60DE9436219 D60DE9436219
# ATM Arena de Girona, spanish transport card # ATM Area de Girona, spanish transport card
A00000000000 A00000000000
A01000000000 A01000000000
@ -2373,3 +2373,9 @@ B12000000000
B13000000000 B13000000000
B14000000000 B14000000000
B15000000000 B15000000000
# TAM - Transporte Alicante Metropolitano (spanish transport card)
# Sectors 9-15
C0C1C2C3C4C5
B0B1B2B3B4B5

View file

@ -3469,6 +3469,7 @@ static int CmdHF14AMfSmartBrute(const char *Cmd) {
if (ret == BF_GENERATOR_ERROR) { if (ret == BF_GENERATOR_ERROR) {
PrintAndLogEx(ERR, "Internal bruteforce generator error"); PrintAndLogEx(ERR, "Internal bruteforce generator error");
free(keyBlock); free(keyBlock);
free(e_sector);
return PM3_EFAILED; return PM3_EFAILED;
} else if (ret == BF_GENERATOR_END) { } else if (ret == BF_GENERATOR_END) {
lastChunk = true; lastChunk = true;
@ -6208,6 +6209,7 @@ int CmdHFMFNDEFRead(const char *Cmd) {
} }
uint8_t ndefkey[6] = {0}; uint8_t ndefkey[6] = {0};
printf("%d", keylen)
memcpy(ndefkey, g_mifare_ndef_key, 6); memcpy(ndefkey, g_mifare_ndef_key, 6);
if (keylen == 6) { if (keylen == 6) {
memcpy(ndefkey, key, 6); memcpy(ndefkey, key, 6);