pub struct DeviceAuthnKey {
pub attestation: Option<Box<DeviceAuthnAttestation>>,
pub client_key_id: Option<String>,
pub created_at: Option<String>,
pub device_name: Option<String>,
pub device_type: Option<String>,
pub public_key: Option<Vec<i32>>,
pub relaxed_attestation_expires_at: Option<String>,
pub state: Option<String>,
pub version: Option<i64>,
}Fields§
§attestation: Option<Box<DeviceAuthnAttestation>>§client_key_id: Option<String>ClientKeyID is a client-chosen id for the key and is unique per identity.
created_at: Option<String>CreatedAt is the timestamp of when the key was created. Only used for troubleshooting/UI.
device_name: Option<String>DeviceName is a human readable name for the device, helping the user to distinguish it from others.
device_type: Option<String>§public_key: Option<Vec<i32>>PublicKey is an EC (in v1) public key, used to verify signatures, stored as uncompressed bytes. The private key resides inside the device and does not exist on the server.
relaxed_attestation_expires_at: Option<String>RelaxedAttestationExpiresAt is set only when the key’s attestation chain validated because relaxed attestation was allowed (software roots, expired certs, software security level) rather than under strict rules. Such keys are second-class: they are refused at login after this time, or immediately if relaxed attestation is turned off. It is nil for hardware-attested keys that pass strict validation.
state: Option<String>§version: Option<i64>v1 uses SHA256 + EC256. v2 (in the future) may use ML-DSA which is post-quantum resistant. This requires Android/iOS support so we have to wait. We intentionally avoid storing the cryptographic algorithm here a la JWT/TLS to avoid security issues and algorithm negotiation.
Implementations§
Source§impl DeviceAuthnKey
impl DeviceAuthnKey
pub fn new() -> DeviceAuthnKey
Trait Implementations§
Source§impl Clone for DeviceAuthnKey
impl Clone for DeviceAuthnKey
Source§fn clone(&self) -> DeviceAuthnKey
fn clone(&self) -> DeviceAuthnKey
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for DeviceAuthnKey
impl Debug for DeviceAuthnKey
Source§impl Default for DeviceAuthnKey
impl Default for DeviceAuthnKey
Source§fn default() -> DeviceAuthnKey
fn default() -> DeviceAuthnKey
Source§impl<'de> Deserialize<'de> for DeviceAuthnKey
impl<'de> Deserialize<'de> for DeviceAuthnKey
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl PartialEq for DeviceAuthnKey
impl PartialEq for DeviceAuthnKey
Source§fn eq(&self, other: &DeviceAuthnKey) -> bool
fn eq(&self, other: &DeviceAuthnKey) -> bool
self and other values to be equal, and is used by ==.