-
Notifications
You must be signed in to change notification settings - Fork 130
ASWebAuthenticationSession Support #226
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
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.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
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.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
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.