add reference to blacktears

This commit is contained in:
iceman1001
2026-04-03 12:20:59 +07:00
parent c33f10f56b
commit d8d221bc81
2 changed files with 24 additions and 22 deletions
+23 -22
View File
@@ -103,32 +103,33 @@ uint8_t g_tearoff_skip = 0;
int tearoff_hook(void) {
if (g_tearoff_enabled) {
if (g_tearoff_enabled == false) {
Dbprintf("no tear off");
return PM3_SUCCESS;
}
// tear off is happening...
if (g_tearoff_delay_us == 0) {
if (g_tearoff_delay_us == 0) {
if (g_dbglevel >= DBG_ERROR) Dbprintf(_RED_("No tear-off delay configured!"));
g_tearoff_enabled = false;
return PM3_SUCCESS; // SUCCESS = the hook didn't do anything
}
if (g_tearoff_skip > 0) {
if (g_dbglevel >= DBG_INFO) Dbprintf(_GREEN_("Tear-off skipped!"));
g_tearoff_skip--;
return PM3_SUCCESS; // SUCCESS = the hook didn't do anything
}
SpinDelayUsPrecision(g_tearoff_delay_us);
FpgaWriteConfWord(FPGA_MAJOR_MODE_OFF);
if (g_dbglevel >= DBG_ERROR) Dbprintf(_RED_("No tear-off delay configured!"));
g_tearoff_enabled = false;
if (g_dbglevel >= DBG_INFO) Dbprintf(_YELLOW_("Tear-off triggered!"));
return PM3_ETEAROFF;
} else {
return PM3_SUCCESS; // SUCCESS = the hook didn't do anything
return PM3_SUCCESS; // SUCCESS = the hook didn't do anything
}
if (g_tearoff_skip > 0) {
if (g_dbglevel >= DBG_INFO) Dbprintf(_GREEN_("Tear-off skipped!"));
g_tearoff_skip--;
return PM3_SUCCESS; // SUCCESS = the hook didn't do anything
}
SpinDelayUsPrecision(g_tearoff_delay_us);
FpgaWriteConfWord(FPGA_MAJOR_MODE_OFF);
g_tearoff_enabled = false;
if (g_dbglevel >= DBG_INFO) Dbprintf(_YELLOW_("Tear-off triggered!"));
return PM3_ETEAROFF;
}
void hf_field_off(void) {
+1
View File
@@ -1412,6 +1412,7 @@ static int CmdTearoff(const char *Cmd) {
PrintAndLogEx(INFO, " lf em 4x05_unlock");
PrintAndLogEx(INFO, " lf t55xx dangerraw");
PrintAndLogEx(INFO, " hf iclass tear");
PrintAndLogEx(INFO, " hf iclass blacktears");
PrintAndLogEx(INFO, " hf mfu otptear");
PrintAndLogEx(INFO, " Standalone mode HF_ST25_TEAROFF");
return PM3_SUCCESS;