Updated on 2026-08-14

This commit is contained in:
Tangem 2018-12-04 15:53:05 +03:00
parent ebc3abcfe1
commit 10c0b8e680
10 changed files with 66 additions and 66 deletions

View file

@ -73,12 +73,12 @@ public class VerifyCardTask extends Thread {
mNotifications.onReadProgress(protocol, 80);
}
if (isCancelled) return;
Firmwares.VerifyCodeRecord record=Firmwares.selectRandomVerifyCodeBlock(mCard.getFirmwareVersion());
Firmwares.VerifyCodeRecord record = Firmwares.selectRandomVerifyCodeBlock(mCard.getFirmwareVersion());
if (isCancelled) return;
if( record!=null ) {
if (record != null) {
byte[] returnedDigest = protocol.run_VerifyCode(record.hashAlg, record.blockIndex, record.blockCount, record.challenge);
mCard.setCodeConfirmed(Arrays.equals(returnedDigest, record.digest));
}else{
} else {
mCard.setCodeConfirmed(null);
}
mNotifications.onReadProgress(protocol, 90);