mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-19 21:03:48 -07:00
Bugfix 'hf list 14b' and 'hf list raw'
This commit is contained in:
parent
41fdd0f061
commit
b689b842b6
1 changed files with 22 additions and 16 deletions
|
@ -519,9 +519,9 @@ int CmdHFList(const char *Cmd)
|
||||||
int tlen = param_getstr(Cmd,0,type);
|
int tlen = param_getstr(Cmd,0,type);
|
||||||
char param = param_getchar(Cmd, 1);
|
char param = param_getchar(Cmd, 1);
|
||||||
bool errors = false;
|
bool errors = false;
|
||||||
uint8_t protocol = false;
|
uint8_t protocol = 0;
|
||||||
//Validate params
|
//Validate params
|
||||||
if(tlen == 0 || (strcmp(type, "iclass") != 0 && strcmp(type,"14a") != 0))
|
if(tlen == 0)
|
||||||
{
|
{
|
||||||
errors = true;
|
errors = true;
|
||||||
}
|
}
|
||||||
|
@ -529,6 +529,25 @@ int CmdHFList(const char *Cmd)
|
||||||
{
|
{
|
||||||
errors = true;
|
errors = true;
|
||||||
}
|
}
|
||||||
|
if(!errors)
|
||||||
|
{
|
||||||
|
if(strcmp(type, "iclass") == 0)
|
||||||
|
{
|
||||||
|
protocol = ICLASS;
|
||||||
|
}else if(strcmp(type, "14a") == 0)
|
||||||
|
{
|
||||||
|
protocol = ISO_14443A;
|
||||||
|
}
|
||||||
|
else if(strcmp(type, "14b") == 0)
|
||||||
|
{
|
||||||
|
protocol = ISO_14443B;
|
||||||
|
}else if(strcmp(type,"raw")== 0)
|
||||||
|
{
|
||||||
|
protocol = -1;//No crc, no annotations
|
||||||
|
}else{
|
||||||
|
errors = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (errors) {
|
if (errors) {
|
||||||
PrintAndLog("List protocol data in trace buffer.");
|
PrintAndLog("List protocol data in trace buffer.");
|
||||||
|
@ -543,20 +562,7 @@ int CmdHFList(const char *Cmd)
|
||||||
PrintAndLog("example: hf list iclass");
|
PrintAndLog("example: hf list iclass");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
if(strcmp(type, "iclass") == 0)
|
|
||||||
{
|
|
||||||
protocol = ICLASS;
|
|
||||||
}else if(strcmp(type, "14a") == 0)
|
|
||||||
{
|
|
||||||
protocol = ISO_14443A;
|
|
||||||
}
|
|
||||||
else if(strcmp(type, "14b") == 0)
|
|
||||||
{
|
|
||||||
protocol = ISO_14443B;
|
|
||||||
}else if(strcmp(type,"raw")== 0)
|
|
||||||
{
|
|
||||||
protocol = -1;//No crc, no annotations
|
|
||||||
}
|
|
||||||
|
|
||||||
if (param == 'f') {
|
if (param == 'f') {
|
||||||
showWaitCycles = true;
|
showWaitCycles = true;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue