mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-23 06:35:38 -07:00
commit
347bf3bd26
2 changed files with 9 additions and 5 deletions
|
@ -455,7 +455,6 @@ const char *CIPURSEGetSMR(uint8_t smr) {
|
||||||
default:
|
default:
|
||||||
return "unknown";
|
return "unknown";
|
||||||
}
|
}
|
||||||
return "unknown";
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void CIPURSEPrintSMR(uint8_t *smrrec) {
|
void CIPURSEPrintSMR(uint8_t *smrrec) {
|
||||||
|
|
|
@ -210,7 +210,9 @@ static int CLIParseCommandParametersEx(CLIParserContext *ctx, size_t keyid, size
|
||||||
*useaid = false;
|
*useaid = false;
|
||||||
if (aidid && aid && aidlen) {
|
if (aidid && aid && aidlen) {
|
||||||
hdatalen = sizeof(hdata);
|
hdatalen = sizeof(hdata);
|
||||||
CLIGetHexWithReturn(ctx, aidid, hdata, &hdatalen);
|
if (CLIParamHexToBuf(arg_get_str(ctx, aidid), hdata, hdatalen, &hdatalen))
|
||||||
|
return PM3_ESOFT;
|
||||||
|
|
||||||
if (hdatalen && (hdatalen < 1 || hdatalen > 16)) {
|
if (hdatalen && (hdatalen < 1 || hdatalen > 16)) {
|
||||||
PrintAndLogEx(ERR, _RED_("ERROR:") " application id length must be 1-16 bytes only");
|
PrintAndLogEx(ERR, _RED_("ERROR:") " application id length must be 1-16 bytes only");
|
||||||
return PM3_EINVARG;
|
return PM3_EINVARG;
|
||||||
|
@ -232,7 +234,9 @@ static int CLIParseCommandParametersEx(CLIParserContext *ctx, size_t keyid, size
|
||||||
*usefid = false;
|
*usefid = false;
|
||||||
if (fidid && fid) {
|
if (fidid && fid) {
|
||||||
hdatalen = sizeof(hdata);
|
hdatalen = sizeof(hdata);
|
||||||
CLIGetHexWithReturn(ctx, fidid, hdata, &hdatalen);
|
if (CLIParamHexToBuf(arg_get_str(ctx, fidid), hdata, hdatalen, &hdatalen))
|
||||||
|
return PM3_ESOFT;
|
||||||
|
|
||||||
if (hdatalen && hdatalen != 2) {
|
if (hdatalen && hdatalen != 2) {
|
||||||
PrintAndLogEx(ERR, _RED_("ERROR:") " file id length must be 2 bytes only");
|
PrintAndLogEx(ERR, _RED_("ERROR:") " file id length must be 2 bytes only");
|
||||||
return PM3_EINVARG;
|
return PM3_EINVARG;
|
||||||
|
@ -250,7 +254,8 @@ static int CLIParseCommandParametersEx(CLIParserContext *ctx, size_t keyid, size
|
||||||
*usechfid = false;
|
*usechfid = false;
|
||||||
if (chfidid && chfid) {
|
if (chfidid && chfid) {
|
||||||
hdatalen = sizeof(hdata);
|
hdatalen = sizeof(hdata);
|
||||||
CLIGetHexWithReturn(ctx, chfidid, hdata, &hdatalen);
|
if (CLIParamHexToBuf(arg_get_str(ctx, chfidid), hdata, hdatalen, &hdatalen))
|
||||||
|
return PM3_ESOFT;
|
||||||
if (hdatalen && hdatalen != 2) {
|
if (hdatalen && hdatalen != 2) {
|
||||||
PrintAndLogEx(ERR, _RED_("ERROR:") " child file id length must be 2 bytes only");
|
PrintAndLogEx(ERR, _RED_("ERROR:") " child file id length must be 2 bytes only");
|
||||||
return PM3_EINVARG;
|
return PM3_EINVARG;
|
||||||
|
@ -961,7 +966,7 @@ static int CmdHFCipurseWriteFileAttr(const char *Cmd) {
|
||||||
SetAPDULogging(APDULogging);
|
SetAPDULogging(APDULogging);
|
||||||
|
|
||||||
if (verbose) {
|
if (verbose) {
|
||||||
PrintAndLogEx(INFO, "attribtes data[%zu]: %s", hdatalen, sprint_hex(hdata, hdatalen));
|
PrintAndLogEx(INFO, "attribtes data[%d]: %s", hdatalen, sprint_hex(hdata, hdatalen));
|
||||||
CIPURSEPrintFileUpdateAttr(hdata, hdatalen);
|
CIPURSEPrintFileUpdateAttr(hdata, hdatalen);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue