Skip to content

Commit 081f894

Browse files
committed
Add JavascriptInterface rules to consumer proguard
1 parent 7fd1e1e commit 081f894

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

changelog.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
vNext
22
----------
3+
- [PATCH] Add JavascriptInterface rules to consumer proguard
34
- [MINOR] Add optimized saveAndLoadAggregatedAccountData method in BrokerOAuth2TokenCache (#2832)
45
- [MINOR] Remove MavenCentral repository from build.gradle files (#2830)
56
- [MINOR] Determine whether broker app opts out from battery optimization (#2819)

common/consumer-rules.pro

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@
2626
-keep class * extends com.microsoft.identity.common.java.authscheme.AbstractAuthenticationScheme { *; }
2727
-keep class com.microsoft.identity.common.internal.broker.AuthUxJsonPayload { *; }
2828

29+
# Keep WebView JS bridge methods annotated with @JavascriptInterface
30+
-keepclassmembers class com.microsoft.identity.** {
31+
@android.webkit.JavascriptInterface <methods>;
32+
}
2933

3034
#For Android Credential Manager: https://developer.android.com/training/sign-in/passkeys#proguard
3135
-if class androidx.credentials.CredentialManager

0 commit comments

Comments
 (0)