mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2024-11-10 09:32:41 +08:00
style
This commit is contained in:
parent
b857369f7a
commit
a2fdab98b5
7 changed files with 29 additions and 11 deletions
|
@ -3470,7 +3470,7 @@ static int CmdBinaryMap(const char *Cmd) {
|
|||
|
||||
int hlen = 5;
|
||||
uint8_t hex[5 + 1];
|
||||
CLIGetStrWithReturn(ctx, 1,hex, &hlen);
|
||||
CLIGetStrWithReturn(ctx, 1, hex, &hlen);
|
||||
|
||||
int tlen = 40;
|
||||
uint8_t template[40 + 1];
|
||||
|
@ -3478,10 +3478,10 @@ static int CmdBinaryMap(const char *Cmd) {
|
|||
CLIParserFree(ctx);
|
||||
|
||||
char bits[(8 * 4) + 1] = {0};
|
||||
hextobinstring_n(bits, (char*)hex, hlen);
|
||||
hextobinstring_n(bits, (char *)hex, hlen);
|
||||
|
||||
int x = 0;
|
||||
char *token = strtok((char*)template, ",");
|
||||
char *token = strtok((char *)template, ",");
|
||||
|
||||
// header
|
||||
PrintAndLogEx(INFO, "---+---------------------------");
|
||||
|
@ -3502,7 +3502,7 @@ static int CmdBinaryMap(const char *Cmd) {
|
|||
// incease with previous offset
|
||||
x += i;
|
||||
|
||||
for (;i < x; i++) {
|
||||
for (; i < x; i++) {
|
||||
PrintAndLogEx(NORMAL, "%c " NOLF, bits[7 - i]);
|
||||
}
|
||||
|
||||
|
|
|
@ -1542,7 +1542,7 @@ static int CmdHF14BDump(const char *Cmd) {
|
|||
PrintAndLogEx(NORMAL, "");
|
||||
return PM3_SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
// save to file
|
||||
if (fnlen < 1) {
|
||||
PrintAndLogEx(INFO, "using UID as filename");
|
||||
|
|
|
@ -1754,7 +1754,7 @@ static int CmdHFiClassDump(const char *Cmd) {
|
|||
arg_lit0("z", "dense", "dense dump output style"),
|
||||
arg_lit0(NULL, "force", "force unsecure card read"),
|
||||
arg_lit0(NULL, "shallow", "use shallow (ASK) reader modulation instead of OOK"),
|
||||
arg_lit0(NULL, "ns", "no save to file"),
|
||||
arg_lit0(NULL, "ns", "no save to file"),
|
||||
arg_param_end
|
||||
};
|
||||
CLIExecWithReturn(ctx, Cmd, argtable, true);
|
||||
|
|
|
@ -107,6 +107,7 @@ const static vocabulary_t vocabulary[] = {
|
|||
{ 1, "data atr" },
|
||||
{ 1, "data bin2hex" },
|
||||
{ 0, "data bitsamples" },
|
||||
{ 1, "data bmap" },
|
||||
{ 1, "data clear" },
|
||||
{ 1, "data diff" },
|
||||
{ 0, "data hexsamples" },
|
||||
|
|
|
@ -267,7 +267,7 @@ main_loop(char *script_cmds_file, char *script_cmd, bool stayInCommandLoop) {
|
|||
bool printprompt = false;
|
||||
if (g_session.pm3_present) {
|
||||
|
||||
switch(g_conn.send_via_ip) {
|
||||
switch (g_conn.send_via_ip) {
|
||||
case PM3_TCPv4:
|
||||
prompt_net = PROXPROMPT_NET_TCPV4;
|
||||
break;
|
||||
|
|
|
@ -275,6 +275,20 @@
|
|||
],
|
||||
"usage": "data bitsamples [-h]"
|
||||
},
|
||||
"data bmap": {
|
||||
"command": "data bmap",
|
||||
"description": "Breaks down a hex value to binary according a template data bmap -d 16 -m 4,4 This will give two rows each with four bits",
|
||||
"notes": [
|
||||
"data bmap -d 3B -m 2,5,1"
|
||||
],
|
||||
"offline": true,
|
||||
"options": [
|
||||
"-h, --help This help",
|
||||
"-d <hex> hex string",
|
||||
"-m <str> binary template"
|
||||
],
|
||||
"usage": "data bmap [-h] [-d <hex>] [-m <str>]"
|
||||
},
|
||||
"data clear": {
|
||||
"command": "data clear",
|
||||
"description": "This function clears the bigbuff on deviceside and graph window",
|
||||
|
@ -2986,6 +3000,7 @@
|
|||
"--new <hex> Specify key as 8 hex bytes",
|
||||
"--nki <dec> New key index to select key from memory 'hf iclass managekeys'",
|
||||
"--csn <hex> Specify a Card Serial Number (CSN) to diversify the key (if omitted will attempt to read a CSN)",
|
||||
"--elite Elite computations applied to new key",
|
||||
"--elite2 Elite computations applied to both old and new key",
|
||||
"--oldelite Elite computations applied only to old key"
|
||||
],
|
||||
|
@ -3092,9 +3107,10 @@
|
|||
"--nr replay of NR/MAC",
|
||||
"-z, --dense dense dump output style",
|
||||
"--force force unsecure card read",
|
||||
"--shallow use shallow (ASK) reader modulation instead of OOK"
|
||||
"--shallow use shallow (ASK) reader modulation instead of OOK",
|
||||
"--ns no save to file"
|
||||
],
|
||||
"usage": "hf iclass dump [-hz] [-f <fn>] [-k <hex>] [--ki <dec>] [--credit <hex>] [--ci <dec>] [--elite] [--raw] [--nr] [--force] [--shallow]"
|
||||
"usage": "hf iclass dump [-hz] [-f <fn>] [-k <hex>] [--ki <dec>] [--credit <hex>] [--ci <dec>] [--elite] [--raw] [--nr] [--force] [--shallow] [--ns]"
|
||||
},
|
||||
"hf iclass eload": {
|
||||
"command": "hf iclass eload",
|
||||
|
@ -11899,8 +11915,8 @@
|
|||
}
|
||||
},
|
||||
"metadata": {
|
||||
"commands_extracted": 690,
|
||||
"commands_extracted": 691,
|
||||
"extracted_by": "PM3Help2JSON v1.00",
|
||||
"extracted_on": "2023-10-19T19:41:49"
|
||||
"extracted_on": "2023-10-22T12:20:10"
|
||||
}
|
||||
}
|
|
@ -126,6 +126,7 @@ Check column "offline" for their availability.
|
|||
|`data atr `|Y |`ATR lookup`
|
||||
|`data bin2hex `|Y |`Converts binary to hexadecimal`
|
||||
|`data bitsamples `|N |`Get raw samples as bitstring`
|
||||
|`data bmap `|Y |`Convert hex value according a binary template`
|
||||
|`data clear `|Y |`Clears bigbuf on deviceside and graph window`
|
||||
|`data diff `|Y |`Diff of input files`
|
||||
|`data hexsamples `|N |`Dump big buffer as hex bytes`
|
||||
|
|
Loading…
Reference in a new issue