My app is currently experiencing login issues on Android 14 (released oct 23) devices.
Microsoft.Identity.Client.MsalClientException: Returned state(xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx) from authorize endpoint is not the same as the one sent(xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx). See https://aka.ms/msal-statemismatcherror for more details. Below is the code I use:
return await PublicClientApplication.AcquireTokenInteractive(scopes)
.WithUseEmbeddedWebView(true)
.WithParentActivityOrWindow(PlatformConfig.Instance.ParentWindow)
.ExecuteAsync()
.ConfigureAwait(false);
I read that using embedded web view true mitigates this issue but I still get the mismatch error.
I have tried to toggle the WithUseEmbeddedWebView but doesn’t change the outcome. The app opens the microsoft b2c login page with the embedded browser, the user authenticates but the app shows a blank screen and the user cannot proceed.