-
Notifications
You must be signed in to change notification settings - Fork 1
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
Added ability to sign in with Passkey #34
Conversation
//Add passkey to the Rownd user | ||
method = PasskeyCoordinatorMethods.SignUp | ||
let anchor: ASPresentationAnchor = (getWindowScene()?.windows.last?.rootViewController?.view.window)! | ||
let bottomSheetController = getWindowScene()?.windows.first?.rootViewController?.presentedViewController as! BottomSheetController |
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.
I wonder if we should just require this to be passed in as a function argument so we don't have to force typecast it, which could result in a crash.
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.
Updated. I added an internal bottomSheetController to the Rownd instance.
I also added guards for iOS versions under 15 for Passkey.
|
||
let assertionRequest = publicKeyCredentialProvider.createCredentialAssertionRequest(challenge: challenge) | ||
|
||
// Also allow the user to use a saved password, if they have one. |
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.
remove password request stuff
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.
Done
// After the server verifies the userName and password, sign in the user. | ||
// didFinishSignIn() | ||
default: | ||
fatalError("Received unknown authorization type.") |
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.
change to a log statement about unsupported authorization type
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.
Updated
Functions to try out
Requirements to enable Passkey on iOS
To test with a dev App, you'll need to set the domain extension with
.dev.rownd.link