adjusting write validation to only print when successful in validating. Otherwise like old times. silence.

This commit is contained in:
iceman1001 2019-09-15 20:27:50 +02:00
commit 44cb67c49b
4 changed files with 45 additions and 25 deletions

View file

@ -168,7 +168,6 @@ static int CmdVisa2kClone(const char *Cmd) {
print_blocks(blocks, 4);
uint8_t res = 0;
PacketResponseNG resp;
// fast push mode
@ -190,14 +189,16 @@ static int CmdVisa2kClone(const char *Cmd) {
PrintAndLogEx(ERR, "Error occurred, device did not respond during write operation.");
return PM3_ETIMEOUT;
}
}
// write block0, needs a detect.
if (i == 0)
t55xxAquireAndDetect(false, 0, blocks[i], false);
bool isok = t55xxVerifyWrite(i, 0, false, false, 0, 0, blocks[i]);
if ( isok == false) {
PrintAndLogEx(WARNING, "Couldn't verify write");
if (t55xxVerifyWrite(i, 0, false, false, 0, 0xFF, blocks[i]) == false)
res++;
}
}
if ( res == 0 )
PrintAndLogEx(SUCCESS, "Success writing to tag");