mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2026-09-11 18:29:22 -07:00
errcount was declared before the key type loop and only reset by a non -11 result, so eleven scattered card errors during the DES pass left the AES pass to break on its first error without trying a key. Count per key type instead. With no -n, detect only ever looked at key 0. Sweep the key numbers the application declares (low nibble of the key settings) instead, falling back to 0x00..0x0D when the settings are unreadable. All keys in an application share an algo, so the first key number that succeeds narrows keytypes[] for the rest. --save now stores the first key found rather than whatever dctx was left holding, and a lost card aborts the sweep. -n <num> behaves exactly as before. Co-Authored-By: Claude Opus 5 (1M context)