mirror of
https://github.com/Proxmark/proxmark3.git
synced 2025-07-30 11:38:38 -07:00
Check keys in hf mf nested and hf mf chk (#414)
Improve hf mf chk and hf mf nested * hf mf chk. added interrupt of procedure by usb * extract mifare default keys into separate module * arm side multisector `hf mf chk` * hf mf nested. change key search procedure * hf mf nested. added key check after we have found a key. * small fix hf list f * hf mf chk. add timeout (arm side) and some tweaks.
This commit is contained in:
parent
77aecdd286
commit
275d9e61c2
14 changed files with 375 additions and 218 deletions
|
@ -139,7 +139,7 @@ int getCommand(UsbCommand* response)
|
|||
* @param ms_timeout
|
||||
* @return true if command was returned, otherwise false
|
||||
*/
|
||||
bool WaitForResponseTimeout(uint32_t cmd, UsbCommand* response, size_t ms_timeout) {
|
||||
bool WaitForResponseTimeoutW(uint32_t cmd, UsbCommand* response, size_t ms_timeout, bool show_warning) {
|
||||
|
||||
UsbCommand resp;
|
||||
|
||||
|
@ -155,7 +155,7 @@ bool WaitForResponseTimeout(uint32_t cmd, UsbCommand* response, size_t ms_timeou
|
|||
}
|
||||
}
|
||||
msleep(10); // XXX ugh
|
||||
if (dm_seconds == 200) { // Two seconds elapsed
|
||||
if (dm_seconds == 200 && show_warning) { // Two seconds elapsed
|
||||
PrintAndLog("Waiting for a response from the proxmark...");
|
||||
PrintAndLog("Don't forget to cancel its operation first by pressing on the button");
|
||||
}
|
||||
|
@ -163,9 +163,12 @@ bool WaitForResponseTimeout(uint32_t cmd, UsbCommand* response, size_t ms_timeou
|
|||
return false;
|
||||
}
|
||||
|
||||
bool WaitForResponseTimeout(uint32_t cmd, UsbCommand* response, size_t ms_timeout) {
|
||||
return WaitForResponseTimeoutW(cmd, response, ms_timeout, true);
|
||||
}
|
||||
|
||||
bool WaitForResponse(uint32_t cmd, UsbCommand* response) {
|
||||
return WaitForResponseTimeout(cmd,response,-1);
|
||||
return WaitForResponseTimeoutW(cmd, response, -1, true);
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue