stable

Clone or download

Read-only

feat: add webauthn lib for strong authentication

Part of story #31177 check my identity when doing a risky action This commit introduces a global ts lib which bring one function: authenticate. This function performs an authentication along WebAuthn protocol and returns if it succeed or not in a ResultAsync object. The Fault is wrapped in Err if not succeed. Already use this library for the Check button in Webauthn user preferences. *Testing:* Just call the function as it is: - If your browser doesn't support WebAuthn, it returns Ok - If you have no registered passkeys, it returns Ok - If authentication failed, ... it returns Err ;) - Else it returns Ok. You can also just click on the button mentionned above. Change-Id: I92d61ad2804cd762bf8aa7abe42ab1337396187e

Modified Files

Name
A lib/frontend/webauthn/.gitignore +1 −0 Go to diff View file
A lib/frontend/webauthn/README.md +28 −0 Go to diff View file
A lib/frontend/webauthn/package.json +34 −0 Go to diff View file
A lib/frontend/webauthn/pnpm-lock.yaml +42 −0 Go to diff View file
A lib/frontend/webauthn/src/main.test.ts +95 −0 Go to diff View file
A lib/frontend/webauthn/src/main.ts +57 −0 Go to diff View file
A lib/frontend/webauthn/tests/stubs/AuthenticationResponseJSON.ts +33 −0 Go to diff View file
A lib/frontend/webauthn/tests/stubs/TuleapAPIFault.ts +31 −0 Go to diff View file
A lib/frontend/webauthn/tsconfig.json +8 −0 Go to diff View file
A lib/frontend/webauthn/vite.config.ts +35 −0 Go to diff View file
M plugins/webauthn/scripts/account/package.json +1 −0 Go to diff View file
M plugins/webauthn/scripts/account/pnpm-lock.yaml +3 −0 Go to diff View file
M plugins/webauthn/scripts/account/src/CustomFault.ts +0 −7 Go to diff View file
M plugins/webauthn/scripts/account/src/account.ts +1 −1 Go to diff View file
D plugins/webauthn/scripts/account/src/authenticate.ts +0 −49 Go to diff View file