chg: \r didn't work well with printandlogex

chg: spaces
chg: cleaning
This commit is contained in:
iceman1001 2018-04-27 12:15:26 +02:00
commit 271cb3e1cc
8 changed files with 18 additions and 19 deletions

View file

@ -41,36 +41,35 @@ int CmdHFSearch(const char *Cmd){
char cmdp = param_getchar(Cmd, 0); char cmdp = param_getchar(Cmd, 0);
if (cmdp == 'h' || cmdp == 'H') return usage_hf_search(); if (cmdp == 'h' || cmdp == 'H') return usage_hf_search();
PrintAndLogEx(NORMAL, "");
int ans = CmdHF14AInfo("s"); int ans = CmdHF14AInfo("s");
if (ans > 0) { if (ans > 0) {
PrintAndLogEx(NORMAL, "\nValid ISO14443-A Tag Found\n"); PrintAndLogEx(SUCCESS, "\nValid ISO14443-A Tag Found\n");
return ans; return ans;
} }
ans = HF15Reader("", false); ans = HF15Reader("", false);
if (ans) { if (ans) {
PrintAndLogEx(NORMAL, "\nValid ISO15693 Tag Found\n"); PrintAndLogEx(SUCCESS, "\nValid ISO15693 Tag Found\n");
return ans; return ans;
} }
ans = HFLegicReader("", false); ans = HFLegicReader("", false);
if ( ans == 0) { if ( ans == 0) {
PrintAndLogEx(NORMAL, "\nValid LEGIC Tag Found\n"); PrintAndLogEx(SUCCESS, "\nValid LEGIC Tag Found\n");
return 1; return 1;
} }
ans = CmdHFTopazReader("s"); ans = CmdHFTopazReader("s");
if (ans == 0) { if (ans == 0) {
PrintAndLogEx(NORMAL, "\nValid Topaz Tag Found\n"); PrintAndLogEx(SUCCESS, "\nValid Topaz Tag Found\n");
return 1; return 1;
} }
// 14b and iclass is the longest test (put last) // 14b and iclass is the longest test (put last)
ans = HF14BReader(false); //CmdHF14BReader("s"); ans = HF14BReader(false); //CmdHF14BReader("s");
if (ans) { if (ans) {
PrintAndLogEx(NORMAL, "\nValid ISO14443-B Tag Found\n"); PrintAndLogEx(SUCCESS, "\nValid ISO14443-B Tag Found\n");
return ans; return ans;
} }
ans = HFiClassReader("", false, false); ans = HFiClassReader("", false, false);
if (ans) { if (ans) {
PrintAndLogEx(NORMAL, "\nValid iClass Tag (or PicoPass Tag) Found\n"); PrintAndLogEx(SUCCESS, "\nValid iClass Tag (or PicoPass Tag) Found\n");
return ans; return ans;
} }

View file

@ -503,7 +503,7 @@ int CmdHF14AInfo(const char *Cmd) {
} }
} }
} else { } else {
PrintAndLogEx(NORMAL, "proprietary non iso14443-4 card found, RATS not supported"); PrintAndLogEx(INFO, "proprietary non iso14443-4 card found, RATS not supported");
} }
detect_classic_magic(); detect_classic_magic();

View file

@ -2254,7 +2254,7 @@ int CmdHF14AMfKeyBrute(const char *Cmd) {
PrintAndLogEx(FAILED, "key not found"); PrintAndLogEx(FAILED, "key not found");
t1 = msclock() - t1; t1 = msclock() - t1;
PrintAndLogEx(NORMAL, "\n"); PrintAndLogEx(SUCCESS, "time in keybrute: %.0f seconds\n", (float)t1/1000.0); PrintAndLogEx(SUCCESS, "\ntime in keybrute: %.0f seconds\n", (float)t1/1000.0);
return 0; return 0;
} }

View file

@ -213,8 +213,8 @@ void UsbCommandReceived(UsbCommand* _ch) {
// print debug line on same row. escape seq \r // print debug line on same row. escape seq \r
if ( c->arg[1] == CMD_MEASURE_ANTENNA_TUNING_HF) { if ( c->arg[1] == CMD_MEASURE_ANTENNA_TUNING_HF) {
PrintAndLogEx(NORMAL, "\r#db# %s", s); printf("\r#db# %s", s);
//fflush(stdout); fflush(stdout);
} else { } else {
PrintAndLogEx(NORMAL, "#db# %s", s); PrintAndLogEx(NORMAL, "#db# %s", s);
} }
@ -236,7 +236,7 @@ void UsbCommandReceived(UsbCommand* _ch) {
uint32_t len = MIN(c->arg[1], sample_buf_size); uint32_t len = MIN(c->arg[1], sample_buf_size);
//uint32_t tracelen = c->arg[2]; //uint32_t tracelen = c->arg[2];
printf("SAMPLE_BUF_SIZE %u | adjusted len %u \n", sample_buf_size, len); //printf("SAMPLE_BUF_SIZE %u | adjusted len %u | offset %u\n", sample_buf_size, len, offset);
memcpy( sample_buf + offset, c->d.asBytes, len); memcpy( sample_buf + offset, c->d.asBytes, len);
//PrintAndLogEx(NORMAL, "ICE:: Download from device. chunk %" PRIu32 " | size %" PRIu32 " | tracelen:%" PRIu32 " \n", offset, len, c->arg[2]); //PrintAndLogEx(NORMAL, "ICE:: Download from device. chunk %" PRIu32 " | size %" PRIu32 " | tracelen:%" PRIu32 " \n", offset, len, c->arg[2]);

View file

@ -156,7 +156,7 @@ int mfCheckKeys_fast( uint8_t sectorsCnt, uint8_t firstChunk, uint8_t lastChunk,
// s70 with 40*2 keys to check, 80*85 = 6800 auth. // s70 with 40*2 keys to check, 80*85 = 6800 auth.
// takes about 97s, still some margin before abort // takes about 97s, still some margin before abort
if (timeout > 180) { if (timeout > 180) {
PrintAndLogEx(NORMAL, "\n"); PrintAndLogEx(WARNING, "no response from Proxmark. Aborting..."); PrintAndLogEx(WARNING, "\nno response from Proxmark. Aborting...");
return 2; return 2;
} }
} }
@ -832,7 +832,7 @@ int mfTraceDecode(uint8_t *data_src, int len, bool wantSaveToEmlFile) {
} }
int tryDecryptWord(uint32_t nt, uint32_t ar_enc, uint32_t at_enc, uint8_t *data, int len){ int tryDecryptWord(uint32_t nt, uint32_t ar_enc, uint32_t at_enc, uint8_t *data, int len){
PrintAndLogEx(NORMAL, "\n"); PrintAndLogEx(SUCCESS, "encrypted data: [%s]", sprint_hex(data, len) ); PrintAndLogEx(SUCCESS, "\nencrypted data: [%s]", sprint_hex(data, len) );
struct Crypto1State *s; struct Crypto1State *s;
ks2 = ar_enc ^ prng_successor(nt, 64); ks2 = ar_enc ^ prng_successor(nt, 64);
ks3 = at_enc ^ prng_successor(nt, 96); ks3 = at_enc ^ prng_successor(nt, 96);