cryptography/passkey_publickey library
Classes
- ParsedPasskeySignature
- The decoded fields of a serialized passkey signature.
- PasskeyPublicKey
-
A passkey public key. Mirrors Mysten's
PasskeyPublicKey(SIP-9): flag0x06, 33-byte compressed secp256r1 point.
Constants
- PASSKEY_PUBLIC_KEY_SIZE → const int
- A passkey (SIP-9) public key: a 33-byte compressed secp256r1 (P-256) point.
- PASSKEY_SIGNATURE_SIZE → const int
- PASSKEY_UNCOMPRESSED_PUBLIC_KEY_SIZE → const int
Properties
- SECP256R1_SPKI_HEADER → Uint8List
-
Fixed DER
SubjectPublicKeyInfoheader for a secp256r1/prime256v1 key. The full SPKI isheader || 0x04 || x || y(65-byte uncompressed point).final
Functions
-
parseDerSPKI(
Uint8List derBytes) → Uint8List -
Parses a DER
SubjectPublicKeyInfointo an uncompressed P-256 point (0x04 || x || y), verifying the fixed secp256r1 header. -
parseSerializedPasskeySignature(
Uint8List signature) → ParsedPasskeySignature -
Parses
flag(0x06) || BCS(PasskeyAuthenticator)into its fields.