Menu

#56 Mutual authentication failed: expected length: 40 + 2, actual length: 2

v1.0_(example)
wont-fix
nobody
JMRTD (3) NFC (1)
1
2026-08-26
2020-08-19
Anonymous
No

Hello, when i wanted to read an ID card throuhg NFC, and the necessary informations were wrong (Expiration date, birth date, serial nuber), I get this error. After changing the informations and made them correct, I keep getting same error. There might be a case that card is blocked somehow. Is there any solution to solve this problem?

2020-08-19 12:42:39.295 11060-11548/com.xxxx W/org.jmrtd: BAC failed
net.sf.scuba.smartcards.CardServiceException: Mutual authentication failed: expected length: 40 + 2, actual length: 2 (SW = 0x6A00: Unknown)
at org.jmrtd.PassportApduService.sendMutualAuth(PassportApduService.java:545)
at org.jmrtd.protocol.BACProtocol.doBACStep(BACProtocol.java:116)
at org.jmrtd.protocol.BACProtocol.doBAC(BACProtocol.java:82)
at org.jmrtd.PassportService.doBAC(PassportService.java:368)
at com.xxxx.util.NFCReaderService$1.doInBackground(NFCReaderService.java:114)
at com.xxxx.util.NFCReaderService$1.doInBackground(NFCReaderService.java:65)
at android.os.AsyncTask$2.call(AsyncTask.java:333)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1162)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636)
at java.lang.Thread.run(Thread.java:764)

Discussion

  • Joseph Milan

    Joseph Milan - 2024-11-08

    Is there any update on this? do you solve this issue

     
  • Martijn Oostdijk

    • status: open --> wont-fix
     
  • Martijn Oostdijk

    Typically that lock is time based: Leave the card powered for 30 seconds or so before trying BAC again usually solves it.

     

Anonymous
Anonymous

Add attachments
Cancel