feat(passkey): passkey provider, passkey login and WebAuthn MFA (server) - #616
feat(passkey): passkey provider, passkey login and WebAuthn MFA (server)#616brkfun wants to merge 1 commit into
Conversation
Server-side implementation of three coordinated passkey features (see the passbolt_styleguide and passbolt_browser_extension counterparts). Passkey / WebAuthn support is a long-standing community request. - Passkey login (passwordless): a new PasskeyAuthentication plugin — login and setup begin/finish (unauthenticated login is anti-enumeration; setup stores the credential + the server half of the passphrase kit), credential management (list / delete by credential id), and a CE organization toggle (admin-only write, unauthenticated-readable). Non-resident credentials so several passkeys can be enrolled per authenticator. - Passkey MFA: WebAuthn/FIDO2 as a new MultiFactorAuthentication provider (setup/verify begin/finish, credentials table + email notifications), mirroring Yubikey/TOTP/Duo. - Passkey provider: a v5-passkey resource type + a passkeys array in the v5 secret definitions, so provider passkeys are stored as encrypted vault secrets. Includes 39 PHPUnit tests (green against a test DB); passes composer cs-check.
|
I was just about to write an issue begging for passkeys to be added; outstanding work |
|
is there anything that i could do to help y'all about this PR? Or else you guys still checking these PR's out. |
|
@brkfun Yeah, we’re still checking these PRs out. That said, we’re probably not going to merge this one as-is. The plan is to ship this in multiple steps, MFA first, then SSO with passkeys, with passkeys themselves being treated as resource types. So we’re looking at this PR more as a PoC that helps speed things up rather than something we’d consider finished and merge directly. |
|
Exactly thats why i just do this as a PoC. I don't recommend or encourage any user to use it. step by step you guys will collab into it. If you need any help about any PR or any section of the PR i'll here and ready to help. Have a nice day! |
|
Thanks a lot @brkfun, your help is very much appreciated. |
|
Passkeys are becoming more critical for business, so I hope to see this merged into release soon. Please keep us updated! ❤️ |
This pull request is a (multiple allowed):
Checklist
What you did
Server-side implementation of the three passkey features above.
New
PasskeyAuthenticationplugin (CE):/passkey/login/begin+/passkey/login/finish(unauthenticated,anti-enumeration — always 200),
/passkey/setup/begin+/passkey/setup/finish(authenrolment storing the credential + the server half of the passphrase kit),
/passkey/collect.GET /passkey/settings(list credentials),DELETE /passkey/settings/{id}(delete one by base64url credential id, or all).
GET/POST /passkey/organization/settingsto enable/disablepasskey login org-wide (admin-only write, unauthenticated-readable).
RESIDENT_KEY_DISCOURAGED) so several passkeys can be enrolled perauthenticator; login supplies the user id + allowCredentials.
MultiFactorAuthentication plugin: WebAuthn/FIDO2 as a new MFA provider (setup/verify
credentials table + email notifications), mirroring the Yubikey / TOTP / Duo structure.
Passkey provider storage: a
v5-passkey-aware resource type + apasskeysarray in the v5 secretdefinitions, so provider passkeys are stored as encrypted vault secrets.
User stories
the server returns assertion options scoped to that user without revealing whether the
persisted; given a non-admin, when they POST, then they get 403.
Fix included
PasskeyOrganizationSettingsService::setEnabled()persisted a raw array where the organization settingstable validates a UTF8 string, so the admin toggle 500'd on every save — now JSON-encode
read side and every other org setting.
Tests
39 new PHPUnit tests (controllers, services, organization settings) executed green locally against a
test DB; existing passkey tests still pass.
composer cs-checkclean.