microsoft-authentication-library-for-objc icon indicating copy to clipboard operation
microsoft-authentication-library-for-objc copied to clipboard

iOS 18 blank sign in screen

Open lukaszciastko-spica opened this issue 1 year ago • 5 comments

Trying to sign in on iOS 18 in the Simulator (using the browser view), all I can see is a blank screen. Tested a few versions of MSAL up to 1.5.1. This works on a real device with the Authenticator app installed (haven't tried without it), but it's an issue during development since we can't sign in into the app.

Simulator Screenshot - iPhone 16 - 2024-09-25 at 19 43 48

lukaszciastko-spica avatar Sep 25 '24 12:09 lukaszciastko-spica

Could you share the xcode version that you are using ? is it iOS18 beta simulator ?

Veena11 avatar Sep 28 '24 00:09 Veena11

Even i am getting the same error. A blank screen while loading simulators running with iOS 18.0. Where as it is working in all previous simulators less than iOS 18. Xcode version is Version 16.0 (16A242d). Is there any solution or workaround for the same?

sabrahamsmartv avatar Sep 30 '24 11:09 sabrahamsmartv

Hi , I tested on xcode 16.1 beta 2 /xcode 16.0 and simulators 18 and 18.1 , but couldnt repro the issue

image image

Veena11 avatar Oct 01 '24 01:10 Veena11

I have resolved the issue by setting the webviewtype to wkwebview. iOS 18 might have introduced changes in SafariViewController or its handling in MSAL, which could have led to the issues with presenting the login page. WKWebView ensures more consistent behavior, so by changing to wkwebview resolved.

Let it be useful to whoever coming to this thread.

    MSALWebviewParameters *webParameters = [[MSALWebviewParameters alloc] initWithAuthPresentationViewController:vc];
webParameters.webviewType = MSALWebviewTypeWKWebView;

sabrahamsmartv avatar Oct 01 '24 07:10 sabrahamsmartv

Thanks @sabrahamsmartv , this works, but I'm not sure this is a long-term solution. As far as I recall, MSALWebviewTypeWKWebView doesn't support passwords fill-in.

@Veena11, when I create a new app and try to reproduce it, it works perfectly fine. I don't think the issue is specifically with MSAL, because I see the same problem when trying to open any link now. But only in our existing app. I can't figure out exactly what's causing it.

lukaszciastko-spica avatar Oct 01 '24 08:10 lukaszciastko-spica

@lukaszciastko-spica , is this issue resolved for you now ? Can we close the ticket ?

Veena11 avatar Nov 21 '24 18:11 Veena11

@lukaszciastko-spica , is this issue resolved for you now ? Can we close the ticket ?

No, we still have the issue and no solution.

lukaszciastko-spica avatar Nov 22 '24 07:11 lukaszciastko-spica

@lukaszciastko-spica did you solve the issue?

vinaykumar0339 avatar Dec 02 '24 04:12 vinaykumar0339

This doesn't seem to be an MSAL issue and maybe an iOS issue. Please reach out to Apple via Dev Forums/Feedback. Closing this

ameyapat avatar Dec 12 '24 23:12 ameyapat

Trying to sign in on iOS 18.2 in the Simulator (using the browser view), all I can see is a blank screen. and it's working fine on the real device.

diwakar445 avatar Jan 16 '25 05:01 diwakar445