ASWebAuthenticationSession Support#226
Conversation
| // if the user touches "done" in safari without entering the credentials the USER_CANCELLED error is sent #71 | ||
| urlHandler.delegate = self.oauth2SafariDelegate | ||
| let urlHandler = ASWebAuthenticationURLHandler( | ||
| callbackUrlScheme: redirectUrl.replacingOccurrences(of: "://oauth", with: ""), |
There was a problem hiding this comment.
Should this be?
callbackUrlScheme: URL(string: redirectUrl)!.scheme!,
So it works with any host url? e.g ://auth
There was a problem hiding this comment.
Yes, it should be as you've written. I've not tested it with other host urls but it should with any url.
|
This PR looks like its gone a little bit quiet. I would love to see this one brought up to date and completed. |
|
Another +1, I'd love to see this get merged in sooner rather than later. Happy to help get it up-to-date with latest main and/or help with feedback if there's any indication the maintainers would merge. |
|
Any update on this one?
The code can be found here: There's not much there, but I think it's more secure and modern. I'll be happy to open a PR if this will help push things forwards. |
|
My usecase doesn't have a strict requirement to use ASWebAuthenticationSession, it's just a nice-to-have, so I'm currently still using this library as-is. |
Switched the authentication method from SafariURLHandler to ASWebAuthenticationURLHandler.
Implemented ASWebAuthenticationPresentationContextProviding in the OAuth2ClientPlugin class.