added a interactive flag for hf14asniff, and unified text across the project
This commit is contained in:
1 parent
c3be58229d
commit
efc8c0b8ab
17 files changed
+35
-20
No files matched your search
+1
-1
@@ -313,7 +313,7 @@ int CmdHFTune(const char *Cmd) {
|
||||
style = STYLE_VALUE;
|
||||
|
||||
PrintAndLogEx(INFO, "Measuring HF antenna");
|
||||
PrintAndLogEx(INFO, "click " _GREEN_("pm3 button") " or press " _GREEN_("<Enter>") " to exit");
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or " _GREEN_("<Enter>") " to exit");
|
||||
PacketResponseNG resp;
|
||||
clearCommandBuffer();
|
||||
|
||||
|
||||
+11
-2
@@ -877,13 +877,14 @@ int CmdHF14ASniff(const char *Cmd) {
|
||||
CLIParserContext *ctx;
|
||||
CLIParserInit(&ctx, "hf 14a sniff",
|
||||
"Collect data from the field and save into command buffer.\n"
|
||||
"Buffer accessible from command 'hf 14a list'",
|
||||
"Buffer accessible from command `hf 14a list`\n",
|
||||
" hf 14a sniff -c -r");
|
||||
|
||||
void *argtable[] = {
|
||||
arg_param_begin,
|
||||
arg_lit0("c", "card", "triggered by first data from card"),
|
||||
arg_lit0("r", "reader", "triggered by first 7-bit request from reader (REQ,WUP,...)"),
|
||||
arg_lit0("r", "reader", "triggered by first 7-bit request from reader (REQ, WUP)"),
|
||||
arg_lit0("i", "interactive", "Console will not be returned until sniff finishes or is aborted"),
|
||||
arg_param_end
|
||||
};
|
||||
CLIExecWithReturn(ctx, Cmd, argtable, true);
|
||||
@@ -898,10 +899,18 @@ int CmdHF14ASniff(const char *Cmd) {
|
||||
param |= 0x02;
|
||||
}
|
||||
|
||||
bool interactive = arg_get_lit(ctx, 3);
|
||||
CLIParserFree(ctx);
|
||||
|
||||
clearCommandBuffer();
|
||||
SendCommandNG(CMD_HF_ISO14443A_SNIFF, (uint8_t *)¶m, sizeof(uint8_t));
|
||||
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " to abort sniffing");
|
||||
if (interactive) {
|
||||
PacketResponseNG resp;
|
||||
WaitForResponse(CMD_HF_ISO14443A_SNIFF, &resp);
|
||||
PrintAndLogEx(INFO, "Done!");
|
||||
}
|
||||
return PM3_SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
@@ -1495,7 +1495,7 @@ static int CmdHF15FindAfi(const char *Cmd) {
|
||||
bool fast = (arg_get_lit(ctx, 1) == false);
|
||||
CLIParserFree(ctx);
|
||||
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or press " _GREEN_("<Enter>") " to exit");
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or " _GREEN_("<Enter>") " to exit");
|
||||
|
||||
struct p {
|
||||
uint32_t flags;
|
||||
|
||||
@@ -1787,7 +1787,7 @@ static int CmdHFFelicaSniff(const char *Cmd) {
|
||||
|
||||
|
||||
PrintAndLogEx(INFO, "Sniff Felica, getting first %" PRIu32 " frames, skipping after %" PRIu32 " triggers", payload.samples, payload.triggers);
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or press " _GREEN_("<Enter>") " to abort sniffing");
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or " _GREEN_("<Enter>") " to abort sniffing");
|
||||
clearCommandBuffer();
|
||||
SendCommandNG(CMD_HF_FELICA_SNIFF, (uint8_t *)&payload, sizeof(payload));
|
||||
PacketResponseNG resp;
|
||||
@@ -1834,7 +1834,7 @@ static int CmdHFFelicaSimLite(const char *Cmd) {
|
||||
CLIParserFree(ctx);
|
||||
|
||||
PrintAndLogEx(NORMAL, "");
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or press " _GREEN_("<Enter>") " to abort simulation");
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or " _GREEN_("<Enter>") " to abort simulation");
|
||||
|
||||
clearCommandBuffer();
|
||||
SendCommandNG(CMD_HF_FELICALITE_SIMULATE, payload.uid, sizeof(payload));
|
||||
@@ -2039,7 +2039,7 @@ static int CmdHFFelicaDumpLite(const char *Cmd) {
|
||||
SendCommandNG(CMD_HF_FELICALITE_DUMP, NULL, 0);
|
||||
PacketResponseNG resp;
|
||||
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or press " _GREEN_("<Enter>") " to abort dumping");
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or " _GREEN_("<Enter>") " to abort dumping");
|
||||
|
||||
uint8_t timeout = 0;
|
||||
while (WaitForResponseTimeout(CMD_ACK, &resp, 2000) == false) {
|
||||
|
||||
@@ -575,7 +575,7 @@ static int CmdHF14AJookiSim(const char *Cmd) {
|
||||
|
||||
PrintAndLogEx(NORMAL, "");
|
||||
PrintAndLogEx(SUCCESS, "Starting simulating");
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or press " _GREEN_("<Enter>") " to abort simulation");
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or " _GREEN_("<Enter>") " to abort simulation");
|
||||
for (;;) {
|
||||
if (kbd_enter_pressed()) {
|
||||
SendCommandNG(CMD_BREAK_LOOP, NULL, 0);
|
||||
|
||||
@@ -556,7 +556,7 @@ static int CmdLegicSim(const char *Cmd) {
|
||||
SendCommandNG(CMD_HF_LEGIC_SIMULATE, (uint8_t *)&payload, sizeof(payload));
|
||||
PacketResponseNG resp;
|
||||
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or press " _GREEN_("<Enter>") " to abort simulation");
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or " _GREEN_("<Enter>") " to abort simulation");
|
||||
for (;;) {
|
||||
if (kbd_enter_pressed()) {
|
||||
SendCommandNG(CMD_BREAK_LOOP, NULL, 0);
|
||||
|
||||
@@ -193,7 +193,7 @@ int CmdHfThinFilmSim(const char *Cmd) {
|
||||
PrintAndLogEx(INFO, "Client side interrupted");
|
||||
PrintAndLogEx(WARNING, "Simulation still running on Proxmark3 till next command or button press");
|
||||
} else {
|
||||
PrintAndLogEx(INFO, "Done");
|
||||
PrintAndLogEx(INFO, "Done!");
|
||||
}
|
||||
return PM3_SUCCESS;
|
||||
}
|
||||
|
||||
+1
-1
@@ -554,7 +554,7 @@ static int CmdDetectReader(const char *Cmd) {
|
||||
else if (hf)
|
||||
arg = 2;
|
||||
|
||||
PrintAndLogEx(INFO, "press pm3 button to change modes and finally exit");
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " to change modes and exit");
|
||||
clearCommandBuffer();
|
||||
SendCommandNG(CMD_LISTEN_READER_FIELD, (uint8_t *)&arg, sizeof(arg));
|
||||
return PM3_SUCCESS;
|
||||
|
||||
@@ -524,7 +524,7 @@ static int CmdAWIDBrute(const char *Cmd) {
|
||||
}
|
||||
|
||||
PrintAndLogEx(SUCCESS, "Bruteforceing AWID %d reader", fmtlen);
|
||||
PrintAndLogEx(SUCCESS, "Press " _GREEN_("pm3 button") " to abort simulation or press " _GREEN_("<Enter>"));
|
||||
PrintAndLogEx(SUCCESS, "Press " _GREEN_("pm3 button") " or " _GREEN_("<Enter>") " to abort simulation");
|
||||
|
||||
uint16_t up = cn;
|
||||
uint16_t down = cn;
|
||||
|
||||
@@ -1237,7 +1237,7 @@ int CmdEM4x50Sim(const char *Cmd) {
|
||||
clearCommandBuffer();
|
||||
SendCommandNG(CMD_LF_EM4X50_SIM, (uint8_t *)&password, sizeof(password));
|
||||
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or press " _GREEN_("<Enter>") " to abort simulation");
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or " _GREEN_("<Enter>") " to abort simulation");
|
||||
|
||||
PacketResponseNG resp;
|
||||
// init to ZERO
|
||||
|
||||
@@ -282,7 +282,7 @@ int CmdEM4x70Brute(const char *Cmd) {
|
||||
return PM3_EINVARG;
|
||||
}
|
||||
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or press " _GREEN_("<Enter>") " to exit");
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or " _GREEN_("<Enter>") " to exit");
|
||||
clearCommandBuffer();
|
||||
PacketResponseNG resp;
|
||||
SendCommandNG(CMD_LF_EM4X70_BRUTE, (uint8_t *)&etd, sizeof(etd));
|
||||
|
||||
@@ -592,7 +592,7 @@ static int CmdHIDBrute(const char *Cmd) {
|
||||
}
|
||||
PrintAndLogEx(NORMAL, "");
|
||||
PrintAndLogEx(INFO, "Started bruteforcing HID Prox reader");
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or press " _GREEN_("<Enter>") " to abort simulation");
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or " _GREEN_("<Enter>") " to abort simulation");
|
||||
PrintAndLogEx(NORMAL, "");
|
||||
// copy values to low.
|
||||
card_low = card_hi;
|
||||
|
||||
@@ -1015,7 +1015,7 @@ static int CmdIndalaBrute(const char *Cmd) {
|
||||
}
|
||||
PrintAndLogEx(NORMAL, "");
|
||||
PrintAndLogEx(INFO, "Started brute-forcing INDALA Prox reader");
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or press " _GREEN_("<Enter>") " to abort simulation");
|
||||
PrintAndLogEx(INFO, "Press " _GREEN_("pm3 button") " or " _GREEN_("<Enter>") " to abort simulation");
|
||||
PrintAndLogEx(NORMAL, "");
|
||||
|
||||
// main loop
|
||||
|
||||
Reference in new issue
Block a user