pub struct Passkey {
pub id: String,
pub user_id: String,
pub public_key: Vec<u8>,
pub sign_count: u32,
pub name: String,
pub created_at: u64,
pub last_used_at: Option<u64>,
}Expand description
Per-user, per-credential passkey record. id is the credentialId
the authenticator returns at registration; the relying party
(= pylon) hands it back in the allowCredentials list at
assertion time so the authenticator knows which key to use.
Fields§
§id: StringBase64url-encoded credentialId — what the authenticator
returns as rawId and the RP echoes in allowCredentials.
user_id: String§public_key: Vec<u8>COSE_Key bytes. Format depends on the chosen algorithm —
we extract x+y+alg at verify time.
sign_count: u32Authenticator’s sign counter — increments on every successful
assertion. RP MUST reject assertions where the new counter
is <= the stored one (cloned-credential detection per
WebAuthn §6.1.1). 0 means the authenticator doesn’t
implement counters (Touch ID, Face ID — they use secure
enclave isolation instead).
name: StringOptional friendly name set by the user (“iPhone”, “Yubikey 5”).
created_at: u64§last_used_at: Option<u64>