Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NullPointerException in isMultipleMRRTsMatchingGivenApp #1278

Open
msyulw opened this issue Jul 31, 2018 · 9 comments
Open

NullPointerException in isMultipleMRRTsMatchingGivenApp #1278

msyulw opened this issue Jul 31, 2018 · 9 comments
Labels
Issue Triage The engineering team has looked into the issue, understood the issue, labelled/classified the issue More Info Additional information is required to diagnose, troubleshoot, or confirm

Comments

@msyulw
Copy link

msyulw commented Jul 31, 2018

java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.equalsIgnoreCase(java.lang.String)' on a null object reference
	at com.microsoft.aad.adal.TokenCacheAccessor.isMultipleMRRTsMatchingGivenApp(TokenCacheAccessor.java:327)
	at com.microsoft.aad.adal.AcquireTokenSilentHandler.tryMRRT(AcquireTokenSilentHandler.java:261)
	at com.microsoft.aad.adal.AcquireTokenSilentHandler.tryRT(AcquireTokenSilentHandler.java:196)
	at com.microsoft.aad.adal.AcquireTokenSilentHandler.getAccessToken(AcquireTokenSilentHandler.java:107)
	at com.microsoft.aad.adal.AcquireTokenRequest.tryAcquireTokenSilentLocally(AcquireTokenRequest.java:438)
	at com.microsoft.aad.adal.AcquireTokenRequest.acquireTokenSilentFlow(AcquireTokenRequest.java:401)
	at com.microsoft.aad.adal.AcquireTokenRequest.tryAcquireTokenSilent(AcquireTokenRequest.java:354)
	at com.microsoft.aad.adal.AcquireTokenRequest.performAcquireTokenRequest(AcquireTokenRequest.java:333)
	at com.microsoft.aad.adal.AcquireTokenRequest.access$200(AcquireTokenRequest.java:47)
	at com.microsoft.aad.adal.AcquireTokenRequest$1.run(AcquireTokenRequest.java:111)
	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)
@hamiltonha hamiltonha added the bug label Nov 13, 2019
@iambmelt iambmelt added Issue Triage The engineering team has looked into the issue, understood the issue, labelled/classified the issue More Info Additional information is required to diagnose, troubleshoot, or confirm and removed bug labels Dec 19, 2019
@iambmelt
Copy link
Member

@msyulw What version are you having this crash in? Can this issue be closed?

@sindhu181994
Copy link

Fatal Exception: java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.equalsIgnoreCase(java.lang.String)' on a null object reference
at com.microsoft.aad.adal.TokenCacheAccessor.isMultipleMRRTsMatchingGivenApp(SourceFile:440)
at com.microsoft.aad.adal.AcquireTokenSilentHandler.tryMRRT(SourceFile:268)
at com.microsoft.aad.adal.AcquireTokenSilentHandler.tryRT(SourceFile:216)
at com.microsoft.aad.adal.AcquireTokenSilentHandler.getAccessToken(SourceFile:114)
at com.microsoft.aad.adal.AcquireTokenRequest.tryAcquireTokenSilentLocally(SourceFile:499)
at com.microsoft.aad.adal.AcquireTokenRequest.acquireTokenSilentFlow(SourceFile:475)
at com.microsoft.aad.adal.AcquireTokenRequest.tryAcquireTokenSilent(SourceFile:379)
at com.microsoft.aad.adal.AcquireTokenRequest.performAcquireTokenRequest(SourceFile:358)
at com.microsoft.aad.adal.AcquireTokenRequest.access$200(SourceFile:57)
at com.microsoft.aad.adal.AcquireTokenRequest$1.run(SourceFile:131)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
at java.lang.Thread.run(Thread.java:919)

@sindhu181994
Copy link

After enabling proguard, we are facing this issue while updating the app.

@suhailali
Copy link

@sindhu181994 I am also facing the same issue. Most of the time after app update users are facing this issue. The app is crashing. My logs are proguarded.
com.microsoft.aad.adal.t0.a SourceFile:83
com.microsoft.aad.adal.e.c SourceFile:15
com.microsoft.aad.adal.e.d SourceFile:15
com.microsoft.aad.adal.e.a SourceFile:9
com.microsoft.aad.adal.d.e SourceFile:3
com.microsoft.aad.adal.d.a SourceFile:63
com.microsoft.aad.adal.d.d SourceFile:3
com.microsoft.aad.adal.d.b SourceFile:2
com.microsoft.aad.adal.d.a SourceFile:3
com.microsoft.aad.adal.d$a.run SourceFile:4
java.util.concurrent.ThreadPoolExecutor.runWorker ThreadPoolExecutor.java:1167
java.util.concurrent.ThreadPoolExecutor$Worker.run ThreadPoolExecutor.java:641
java.lang.Thread.run Thread.java:919

@iambmelt, Will there be any fix happening on this? If not what can be done from our codebase to resolve or catch this, so that the app won't crash. I have already tried wrapping with a try-catch, but the error is not propagating back to my code.

@suhailali
Copy link

@msyulw @sindhu181994, Did you fix the issue. If yes please post the fix.

@iambmelt
Copy link
Member

@sindhu181994
Copy link

@iambmelt Already disabled obfuscation of ADAL, but still it is happening after app update

@ali-suhail
Copy link

@sindhu181994 Yes, you are right.

@iambmelt Please have a look at this PR #1550 by zeee4real.

@iambmelt
Copy link
Member

iambmelt commented Aug 6, 2021

Removing assignee as they're no longer contributing to this project

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue Triage The engineering team has looked into the issue, understood the issue, labelled/classified the issue More Info Additional information is required to diagnose, troubleshoot, or confirm
Projects
None yet
Development

No branches or pull requests

7 participants