Skip to content

Error trying to scan ID "Access to file denied" #108

Description

@Benkralex

Steps to reproduce

Device: Pixel 8
OS: Android 16 (CP1A.260405.005)

  • Git clone
  • ./gradlew assembleDebug
  • install Demo apk
  • Setup with ID (2.Option)
  • Scan ID (Cam)
  • Scan ID (NFC)
  • Error "Access to file denied"

ADB Logcat Output

2026-04-26 21:51:08.545  1485-1950  ActivityTaskManager     system_server                        E  Background activity launch blocked! goo.gle/android-bal [callingPackage: com.scytales.av; callingPackageTargetSdk: 36; callingUid: 10411; callingPid: -1; appSwitchState: 2; callingUidHasVisibleActivity: true; callingUidHasVisibleNotPinnedActivity: true; callingUidHasNonAppVisibleWindow: false; callingUidProcState: TOP; isCallingUidPersistentSystemProcess: false; allowBalExemptionForSystemProcess: false; intent: Intent { act=android.nfc.action.TAG_DISCOVERED flg=0x20000000 xflg=0x4 cmp=com.scytales.av/eu.europa.ec.passportscanner.nfc.NFCActivity (has extras) }; callerApp: null; balAllowedByPiCreator: BSP.NONE; resultIfPiCreatorAllowsBal: BAL_ALLOW_VISIBLE_WINDOW; callerStartMode: MODE_BACKGROUND_ACTIVITY_START_SYSTEM_DEFINED; hasRealCaller: true; isCallForResult: false; isPendingIntent: true; autoOptInReason: null; realCallingPackage: com.google.android.nfc; realCallingPackageTargetSdk: 36; realCallingUid: 1027; realCallingPid: 2376; realCallingUidHasVisibleActivity: false; realCallingUidHasVisibleNotPinnedActivity: false; realCallingUidHasNonAppVisibleWindow: false; realCallingUidProcState: PERSISTENT; isRealCallingUidPersistentSystemProcess: true; originatingPendingIntent: PendingIntentRecord{1ebedfc com.scytales.av startActivity}; realCallerApp: null; balAllowedByPiSender: BSP.ALLOW_FGS; resultIfPiSenderAllowsBal: BAL_BLOCK; realCallerStartMode: MODE_BACKGROUND_ACTIVITY_START_SYSTEM_DEFINED; balDontBringExistingBackgroundTaskStackToFg: true]
2026-04-26 21:51:08.722  6366-14736 NFCFragment             com.scytales.av                      D  onNFCSReadStart
2026-04-26 21:51:08.735  6366-14736 PassportNFC             com.scytales.av                      I  Inspecting card access file
2026-04-26 21:51:08.856  6366-14736 org.jmrtd               com.scytales.av                      W  Wrong version. Was expecting 1 or 2, found 3
2026-04-26 21:51:08.857  6366-14736 org.jmrtd               com.scytales.av                      W  Unsupported SecurityInfo, oid = 0.4.0.127.0.7.2.2.11.1.2.3
2026-04-26 21:51:08.857  6366-14736 org.jmrtd               com.scytales.av                      W  Unsupported SecurityInfo, oid = 0.4.0.127.0.7.2.2.3.2
2026-04-26 21:51:08.857  6366-14736 org.jmrtd               com.scytales.av                      W  Unsupported SecurityInfo, oid = 0.4.0.127.0.7.2.2.3.2
2026-04-26 21:51:08.857  6366-14736 org.jmrtd               com.scytales.av                      W  Unsupported SecurityInfo, oid = 0.4.0.127.0.7.2.2.6
2026-04-26 21:51:08.857  6366-14736 org.jmrtd               com.scytales.av                      W  Unsupported SecurityInfo, oid = 0.4.0.127.0.7.2.2.8
2026-04-26 21:51:08.861  6366-14736 org.jmrtd               com.scytales.av                      W  Wrong version. Was expecting 1 or 2, found 3
2026-04-26 21:51:08.862  6366-14736 org.jmrtd               com.scytales.av                      W  Unsupported SecurityInfo, oid = 0.4.0.127.0.7.2.2.11.1.2.3
2026-04-26 21:51:08.862  6366-14736 org.jmrtd               com.scytales.av                      W  Unsupported SecurityInfo, oid = 0.4.0.127.0.7.2.2.3.2
2026-04-26 21:51:08.862  6366-14736 org.jmrtd               com.scytales.av                      W  Unsupported SecurityInfo, oid = 0.4.0.127.0.7.2.2.3.2
2026-04-26 21:51:08.862  6366-14736 org.jmrtd               com.scytales.av                      W  Unsupported SecurityInfo, oid = 0.4.0.127.0.7.2.2.6
2026-04-26 21:51:08.862  6366-14736 org.jmrtd               com.scytales.av                      W  Unsupported SecurityInfo, oid = 0.4.0.127.0.7.2.2.8
2026-04-26 21:51:08.953  6366-14736 PassportNFC             com.scytales.av                      E  Attempt to read EF.COM before BAC failed with
                                                                                                    net.sf.scuba.smartcards.CardServiceException: Access to file denied, CAPDU = 00A4020C02011E, RAPDU = 6982 (SW = 0x6982: SECURITY STATUS NOT SATISFIED)
                                                                                                    	at org.jmrtd.protocol.ReadBinaryAPDUSender.checkStatusWordAfterFileOperation(ReadBinaryAPDUSender.java:252)
                                                                                                    	at org.jmrtd.protocol.ReadBinaryAPDUSender.sendSelectFile(ReadBinaryAPDUSender.java:90)
                                                                                                    	at org.jmrtd.DefaultFileSystem.sendSelectFile(DefaultFileSystem.java:383)
                                                                                                    	at org.jmrtd.DefaultFileSystem.getFileInfo(DefaultFileSystem.java:310)
                                                                                                    	at org.jmrtd.DefaultFileSystem.getSelectedPath(DefaultFileSystem.java:157)
                                                                                                    	at net.sf.scuba.smartcards.CardFileInputStream.<init>(CardFileInputStream.java:59)
                                                                                                    	at org.jmrtd.PassportService.getInputStream(PassportService.java:656)
                                                                                                    	at org.jmrtd.PassportService.getInputStream(PassportService.java:632)
                                                                                                    	at eu.europa.ec.passportscanner.nfc.passport.PassportNFC.<init>(PassportNFC.kt:251)
                                                                                                    	at eu.europa.ec.passportscanner.nfc.details.NFCDocumentTag.handleTag$lambda$0(NFCDocumentTag.kt:62)
                                                                                                    	at eu.europa.ec.passportscanner.nfc.details.NFCDocumentTag$$ExternalSyntheticLambda0.call(D8$$SyntheticClass:0)
                                                                                                    	at io.reactivex.internal.operators.single.SingleFromCallable.subscribeActual(SingleFromCallable.java:44)
                                                                                                    	at io.reactivex.Single.subscribe(Single.java:3666)
                                                                                                    	at io.reactivex.internal.operators.single.SingleDoOnSubscribe.subscribeActual(SingleDoOnSubscribe.java:41)
                                                                                                    	at io.reactivex.Single.subscribe(Single.java:3666)
                                                                                                    	at io.reactivex.internal.operators.single.SingleSubscribeOn$SubscribeOnObserver.run(SingleSubscribeOn.java:89)
                                                                                                    	at io.reactivex.Scheduler$DisposeTask.run(Scheduler.java:608)
                                                                                                    	at io.reactivex.internal.schedulers.ScheduledRunnable.run(ScheduledRunnable.java:66)
                                                                                                    	at io.reactivex.internal.schedulers.ScheduledRunnable.call(ScheduledRunnable.java:57)
                                                                                                    	at java.util.concurrent.FutureTask.run(FutureTask.java:317)
                                                                                                    	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:348)
                                                                                                    	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1154)
                                                                                                    	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:652)
                                                                                                    	at java.lang.Thread.run(Thread.java:1564)
2026-04-26 21:51:09.023  6366-6366  NFCFragment             com.scytales.av                      D  onNFCReadFinish
2026-04-26 21:51:09.026  6366-6366  NFCActivity             com.scytales.av                      E  Access to file denied, CAPDU = 00A4020C02011E, RAPDU = 6982 (SW = 0x6982: SECURITY STATUS NOT SATISFIED)
                                                                                                    net.sf.scuba.smartcards.CardServiceException: Access to file denied, CAPDU = 00A4020C02011E, RAPDU = 6982 (SW = 0x6982: SECURITY STATUS NOT SATISFIED)
                                                                                                    	at org.jmrtd.protocol.ReadBinaryAPDUSender.checkStatusWordAfterFileOperation(ReadBinaryAPDUSender.java:252)
                                                                                                    	at org.jmrtd.protocol.ReadBinaryAPDUSender.sendSelectFile(ReadBinaryAPDUSender.java:90)
                                                                                                    	at org.jmrtd.DefaultFileSystem.sendSelectFile(DefaultFileSystem.java:383)
                                                                                                    	at org.jmrtd.DefaultFileSystem.getFileInfo(DefaultFileSystem.java:310)
                                                                                                    	at org.jmrtd.DefaultFileSystem.getSelectedPath(DefaultFileSystem.java:157)
                                                                                                    	at net.sf.scuba.smartcards.CardFileInputStream.<init>(CardFileInputStream.java:59)
                                                                                                    	at org.jmrtd.PassportService.getInputStream(PassportService.java:656)
                                                                                                    	at org.jmrtd.PassportService.getInputStream(PassportService.java:632)
                                                                                                    	at eu.europa.ec.passportscanner.nfc.passport.PassportNFC.getComFile(PassportNFC.kt:1384)
                                                                                                    	at eu.europa.ec.passportscanner.nfc.passport.PassportNFC.<init>(PassportNFC.kt:312)
                                                                                                    	at eu.europa.ec.passportscanner.nfc.details.NFCDocumentTag.handleTag$lambda$0(NFCDocumentTag.kt:62)
                                                                                                    	at eu.europa.ec.passportscanner.nfc.details.NFCDocumentTag$$ExternalSyntheticLambda0.call(D8$$SyntheticClass:0)
                                                                                                    	at io.reactivex.internal.operators.single.SingleFromCallable.subscribeActual(SingleFromCallable.java:44)
                                                                                                    	at io.reactivex.Single.subscribe(Single.java:3666)
                                                                                                    	at io.reactivex.internal.operators.single.SingleDoOnSubscribe.subscribeActual(SingleDoOnSubscribe.java:41)
                                                                                                    	at io.reactivex.Single.subscribe(Single.java:3666)
                                                                                                    	at io.reactivex.internal.operators.single.SingleSubscribeOn$SubscribeOnObserver.run(SingleSubscribeOn.java:89)
                                                                                                    	at io.reactivex.Scheduler$DisposeTask.run(Scheduler.java:608)
                                                                                                    	at io.reactivex.internal.schedulers.ScheduledRunnable.run(ScheduledRunnable.java:66)
                                                                                                    	at io.reactivex.internal.schedulers.ScheduledRunnable.call(ScheduledRunnable.java:57)
                                                                                                    	at java.util.concurrent.FutureTask.run(FutureTask.java:317)
                                                                                                    	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:348)
                                                                                                    	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1154)
                                                                                                    	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:652)
                                                                                                    	at java.lang.Thread.run(Thread.java:1564)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions