webauthn_components icon indicating copy to clipboard operation
webauthn_components copied to clipboard

Support Multiple Keys Per User

Open type1fool opened this issue 2 years ago • 2 comments
trafficstars

Often, a user may want to register additional keys after creating an account for backup or survivorship purposes. The Passkey package should provide an API for registering additional keys when an application wants to support this feature.

Acceptance Criteria

  • [ ] Must add SecondaryPasskey LiveComponent
  • [ ] Must pass user.id & user.displayName to handlePasskeyRegistration in passkey_hook.js
  • [ ] Must update demo app to illustrate component usage
  • [ ] TBD

type1fool avatar Dec 20 '22 04:12 type1fool

Update

It appears the attestation's raw_id would need to be passed as the first arg to Wax.authenticate/6 based on the current API (0.6.0). Then, a list of credentials would be passed as the last argument.

However, the list cannot be just a list of UserKey structs from the parent LiveView. Instead, the list must contain tuples where the first element is the key_id and the second element is the public_key.

Since LV apps will certainly have different structures for storing this data, I'm not yet sure whether the parent LV app should be allowed to send structs, or whether it should be forced to send the list of tuples required by Wax. TBD.

Resources

type1fool avatar Feb 19 '23 21:02 type1fool

I would like to give this one a go @type1fool . Do you have any work done on it yet? Maybe some secret local branch?

peaceful-james avatar Jul 04 '24 10:07 peaceful-james