This commit is contained in:
iceman1001 committed 2024-04-07 11:38:51 +02:00
1 parent 9ba8937f3c
commit 4e540053e9
28 files changed
+2007 -2066

No files matched your search

+3 -3
View File
@@ -1146,7 +1146,7 @@ void binstr_2_bytes(uint8_t *target, size_t *targetlen, const char *src) {
}
void hex_xor(uint8_t *d, uint8_t *x, int n) {
while(n--) {
while (n--) {
d[n] ^= x[n];
}
}
@@ -1488,7 +1488,7 @@ uint8_t get_highest_frequency(const uint8_t *d, uint8_t n) {
uint8_t v = 0;
// Count the frequency of each byte
for(uint8_t i = 0; i < n; i++) {
for (uint8_t i = 0; i < n; i++) {
frequency[d[i]]++;
if (frequency[d[i]] > highest) {
@@ -1498,4 +1498,4 @@ uint8_t get_highest_frequency(const uint8_t *d, uint8_t n) {
}
PrintAndLogEx(DEBUG, "highest occurance... %u xor byte... 0x%02X", highest, v);
return v;
}
}