Skip to content

feat(passkey-crypto): add @bitgo/passkey-crypto package#8595

Closed
derranW26 wants to merge 1 commit into
masterfrom
passkey/ticket-1-passkey-crypto-package-v2
Closed

feat(passkey-crypto): add @bitgo/passkey-crypto package#8595
derranW26 wants to merge 1 commit into
masterfrom
passkey/ticket-1-passkey-crypto-package-v2

Conversation

@derranW26
Copy link
Copy Markdown
Contributor

Summary

  • Adds new modules/passkey-crypto/ package (@bitgo/passkey-crypto) as the cryptographic foundation for the passkey feature (Ticket 1 of 9)
  • derivePassword(prfResult: ArrayBuffer): string — converts WebAuthn PRF output to a hex walletPassphrase for SJCL encryption
  • deriveEnterpriseSalt(baseSalt: string, enterpriseId: string): string — HMAC-SHA256 enterprise-scoped salt to prevent cross-enterprise key reuse

Test plan

  • yarn unit-test in modules/passkey-crypto/ — 11 tests passing (known vectors for both functions)
  • No any types
  • Package builds via yarn build in the module

Pure cryptographic primitives for WebAuthn PRF-based key derivation:
- derivePassword: converts ArrayBuffer PRF result to hex walletPassphrase
- deriveEnterpriseSalt: HMAC-SHA256(baseSalt, enterpriseId) for cross-enterprise isolation
@derranW26 derranW26 closed this Apr 22, 2026
@derranW26 derranW26 deleted the passkey/ticket-1-passkey-crypto-package-v2 branch April 22, 2026 01:51
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.

1 participant