ASWebAuthenticationSession won't open the Safari login window on Monterey

Apple Recommended

  • The problem has been fixed just for Safari, all other browsers seem to exhibit the same old behaviour on latest Ventura 13.1 - like the queue of web authentication requests never gets advanced, and the only way to fix it is either close the browser auth window or restart browser altogether. And it happens on any major browser, except, Safari, of course. Please fix it ASAP

Add a Comment

Replies

Ok, I guess I fixed it, for now.

Even though i'd tried rebooting the Mac, closing Safari then trying this login did in fact open Safari correctly. It even presented me with the 30+ login windows that had previously not opened.

So it's working again now, but I don't know why it got stuck.

This happens to my app too. I'm now using a WebKit view instead, for a more predictable sign in flow.

This is absolutely not fixed. We use the Auth0 SDK for Oauth2 authentication across various Apple devices, which on macOS wraps ASWebAuthenticationSession, and encounter this behavior relatively frequently. We see it on Monterey, across Safari, Chrome and Brave browsers.

I am surprised this isn't getting more attention. The problem is pretty nasty once it triggers -- the user has no idea what is happening or why the login dialog doesn't pop up, and the calling application has no way to detect the condition.

We reported it to Auth0 and they closed our bug pretty quickly -- everyone seems to understand this is Apple's problem.

Post not yet marked as solved Up vote reply of jpr5 Down vote reply of jpr5

I can confirm this issue. It is sporadic and hard to pin down, making it difficult to debug. But when it does happen, the experience is very bad for the user: there is no login possible. And when they close and re-open their browser at a later time, they are surprised with the login window; which is very jarring.

Has anyone found a fix to this? I just posted a question on a couple of ASWebAuthenticationSession issues I'm seeing and just realised that one of them looks a lot like this one (apologies for the duplicate if so).

Same problem here - since months. Also very surprised Apple isn't interested in fixing this.

Could someone from Apple please comment on this?

I am also experiencing this issue when trying to use Auth0 on macOS Monterrey. Anyone been able to figure out a workaround?

We are having this issue as well. Did anyone come up with a workaround? Could anyone from Apple please advise?

Hi guys,

We also have similar problem with ASWebAuthenticationSession on 10.15.

The issue occurs when Safari is selected as default browser and it is been used for a while before the session starts.

When it happens login window does not show up and CompletionHandler is never called.

Closing Safari process helps to overcome the issue and the session window appears immediately after the current process is closed.

It seems to be something wrong between OS and Safari, which prevents it to behave normally.

Any help with the issue would be highly appreciated.

The same issue happening for me on Monterrey, please fix that.

Same here on Monterey 12.2 - I had Safari running for a long time (with lots of open windows and tons of tabs). The UI for ASWebAuthenticationSession never showed up, even when trying multiple times. After quitting and relaunching Safari, all the queued requests for ASWebAuthenticationSession were handled in a serial fashion. This is clearly broken. Please fix in macOS 13.

I hope everyone is filing bug reports for this.

  • Also, please post you bug numbers.

Add a Comment

Also posted a bug report FB10031739

Add a Comment
  • The problem has been fixed just for Safari, all other browsers seem to exhibit the same old behaviour on latest Ventura 13.1 - like the queue of web authentication requests never gets advanced, and the only way to fix it is either close the browser auth window or restart browser altogether. And it happens on any major browser, except, Safari, of course. Please fix it ASAP

Add a Comment