]> cvs.zerfleddert.de Git - proxmark3-svn/blobdiff - client/cmdhf14a.c
Legic: rewrite reader to use xcorrelation and precise timing (#654)
[proxmark3-svn] / client / cmdhf14a.c
index 856d37b35c5a4182c875e2abc4cd3b8c8ac3db4a..03ab0b5a69f8b3e83e725af73b99ed3b464f84fa 100644 (file)
@@ -20,8 +20,7 @@
 #include "util.h"
 #include "util_posix.h"
 #include "iso14443crc.h"
 #include "util.h"
 #include "util_posix.h"
 #include "iso14443crc.h"
-#include "data.h"
-#include "proxmark3.h"
+#include "comms.h"
 #include "ui.h"
 #include "cmdparser.h"
 #include "common.h"
 #include "ui.h"
 #include "cmdparser.h"
 #include "common.h"
@@ -487,12 +486,12 @@ int CmdHF14AInfo(const char *Cmd)
 
        
        // try to see if card responses to "chinese magic backdoor" commands.
 
        
        // try to see if card responses to "chinese magic backdoor" commands.
-       mfCIdentify();
+       (void)mfCIdentify();
        
        if (isMifareClassic) {          
                switch(DetectClassicPrng()) {
                case 0:
        
        if (isMifareClassic) {          
                switch(DetectClassicPrng()) {
                case 0:
-                       PrintAndLog("Prng detection: HARDEND (hardnested)");            
+                       PrintAndLog("Prng detection: HARDENED (hardnested)");           
                        break;
                case 1:
                        PrintAndLog("Prng detection: WEAK");
                        break;
                case 1:
                        PrintAndLog("Prng detection: WEAK");
@@ -770,7 +769,7 @@ int CmdHF14AAPDU(const char *cmd) {
                                        return 1;
                        }
                        
                                        return 1;
                        }
                        
-               if (isxdigit(c)) {
+               if (isxdigit((unsigned char)c)) {
                        // len = data + PCB(1b) + CRC(2b)
                        switch(param_gethex_to_eol(cmd, cmdp, data, sizeof(data) - 1 - 2, &datalen)) {
                        case 1:
                        // len = data + PCB(1b) + CRC(2b)
                        switch(param_gethex_to_eol(cmd, cmdp, data, sizeof(data) - 1 - 2, &datalen)) {
                        case 1:
@@ -1033,12 +1032,9 @@ static command_t CommandTable[] =
 };
 
 int CmdHF14A(const char *Cmd) {
 };
 
 int CmdHF14A(const char *Cmd) {
-       // flush
-       WaitForResponseTimeout(CMD_ACK,NULL,100);
-
-       // parse
-  CmdsParse(CommandTable, Cmd);
-  return 0;
+       (void)WaitForResponseTimeout(CMD_ACK,NULL,100);
+       CmdsParse(CommandTable, Cmd);
+       return 0;
 }
 
 int CmdHelp(const char *Cmd)
 }
 
 int CmdHelp(const char *Cmd)
Impressum, Datenschutz