8000 fix (passkeys): Add custom encoding for PublicKeyCredentialUserEntity by kelvin-chappell · Pull Request #583 · guardian/janus-app · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

fix (passkeys): Add custom encoding for PublicKeyCredentialUserEntity #583

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

Merged
merged 1 commit into from
May 21, 2025

Conversation

kelvin-chappell
Copy link
Member

What is the purpose of this change?

This change ensures that the user ID is base64url encoded when it's presented to PublicKeyCredential.parseCreationOptionsFromJSON in the browser.

What is the value of this change and how do we measure success?

Without this change, certain users whose names are encoded in a way that doesn't produce a base64url encoded string will be rejected in some browsers, at least Chrome.
We see error:

Error during passkey registration: Error during passkey registration: EncodingError: Failed to execute 'parseCreationOptionsFromJSON' on 'PublicKeyCredential': 'user.id' contains invalid base64url data

@kelvin-chappell kelvin-chappell requested a review from a team May 21, 2025 14:21 8000
Copy link
Contributor
@tjsilver tjsilver left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested locally and successfully registered a passkey on Chrome! 👍

@kelvin-chappell kelvin-chappell merged commit 4c29bb5 into main May 21, 2025
6 checks passed
@kelvin-chappell kelvin-chappell deleted the kc/user-encoding branch May 21, 2025 14:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
< 3179 /div>
0