mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-19 21:03:48 -07:00
add print error if smart card functionality not defined
This commit is contained in:
parent
fe66f0fac4
commit
ed991e76b4
1 changed files with 17 additions and 1 deletions
|
@ -792,6 +792,14 @@ int CmdEMVExec(const char *cmd) {
|
||||||
uint8_t psenum = (channel == ECC_CONTACT) ? 1 : 2;
|
uint8_t psenum = (channel == ECC_CONTACT) ? 1 : 2;
|
||||||
CLIParserFree();
|
CLIParserFree();
|
||||||
|
|
||||||
|
#ifndef WITH_SMARTCARD
|
||||||
|
// not compiled with smartcard functionality, we need to exit
|
||||||
|
if ( channel == ECC_CONTACT ) {
|
||||||
|
PrintAndLogEx(WARNING, "PM3 Client is not compiled with support for SMARTCARD. Exiting.");
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
SetAPDULogging(showAPDU);
|
SetAPDULogging(showAPDU);
|
||||||
|
|
||||||
// init applets list tree
|
// init applets list tree
|
||||||
|
@ -1380,6 +1388,14 @@ int CmdEMVScan(const char *cmd) {
|
||||||
CLIGetStrWithReturn(12, relfname, &relfnamelen);
|
CLIGetStrWithReturn(12, relfname, &relfnamelen);
|
||||||
CLIParserFree();
|
CLIParserFree();
|
||||||
|
|
||||||
|
#ifndef WITH_SMARTCARD
|
||||||
|
// not compiled with smartcard functionality, we need to exit
|
||||||
|
if ( channel == ECC_CONTACT ) {
|
||||||
|
PrintAndLogEx(WARNING, "PM3 Client is not compiled with support for SMARTCARD. Exiting.");
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
SetAPDULogging(showAPDU);
|
SetAPDULogging(showAPDU);
|
||||||
|
|
||||||
// current path + file name
|
// current path + file name
|
||||||
|
@ -1418,7 +1434,6 @@ int CmdEMVScan(const char *cmd) {
|
||||||
if (Hf14443_4aGetCardData(&card)) {
|
if (Hf14443_4aGetCardData(&card)) {
|
||||||
return 2;
|
return 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
JsonSaveStr(root, "$.Card.Contactless.Communication", "iso14443-4a");
|
JsonSaveStr(root, "$.Card.Contactless.Communication", "iso14443-4a");
|
||||||
JsonSaveBufAsHex(root, "$.Card.Contactless.UID", (uint8_t *)&card.uid, card.uidlen);
|
JsonSaveBufAsHex(root, "$.Card.Contactless.UID", (uint8_t *)&card.uid, card.uidlen);
|
||||||
|
@ -1702,6 +1717,7 @@ int CmdEMVRoca(const char *cmd) {
|
||||||
if (arg_get_lit(2))
|
if (arg_get_lit(2))
|
||||||
channel = ECC_CONTACT;
|
channel = ECC_CONTACT;
|
||||||
PrintChannel(channel);
|
PrintChannel(channel);
|
||||||
|
CLIParserFree();
|
||||||
|
|
||||||
#ifndef WITH_SMARTCARD
|
#ifndef WITH_SMARTCARD
|
||||||
// not compiled with smartcard functionality, we need to exit
|
// not compiled with smartcard functionality, we need to exit
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue