pub struct Credential {
pub credential_id: Binary,
pub is_resident_credential: bool,
pub rp_id: Option<String>,
pub private_key: Binary,
pub user_handle: Option<Binary>,
pub sign_count: i64,
pub large_blob: Option<Binary>,
pub backup_eligibility: Option<bool>,
pub backup_state: Option<bool>,
}
Fields§
§credential_id: Binary
§is_resident_credential: bool
§rp_id: Option<String>
Relying Party ID the credential is scoped to. Must be set when adding a credential.
private_key: Binary
The ECDSA P-256 private key in PKCS#8 format.
user_handle: Option<Binary>
An opaque byte sequence with a maximum size of 64 bytes mapping the credential to a specific user.
sign_count: i64
Signature counter. This is incremented by one for each successful assertion. See https://w3c.github.io/webauthn/#signature-counter
large_blob: Option<Binary>
The large blob associated with the credential. See https://w3c.github.io/webauthn/#sctn-large-blob-extension
backup_eligibility: Option<bool>
Assertions returned by this credential will have the backup eligibility (BE) flag set to this value. Defaults to the authenticator’s defaultBackupEligibility value.
backup_state: Option<bool>
Assertions returned by this credential will have the backup state (BS) flag set to this value. Defaults to the authenticator’s defaultBackupState value.
Implementations§
Source§impl Credential
impl Credential
Source§impl Credential
impl Credential
pub fn builder() -> CredentialBuilder
Source§impl Credential
impl Credential
pub const IDENTIFIER: &'static str = "WebAuthn.Credential"
Trait Implementations§
Source§impl Clone for Credential
impl Clone for Credential
Source§fn clone(&self) -> Credential
fn clone(&self) -> Credential
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for Credential
impl Debug for Credential
Source§impl<'de> Deserialize<'de> for Credential
impl<'de> Deserialize<'de> for Credential
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<Credential, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<Credential, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Source§impl PartialEq for Credential
impl PartialEq for Credential
Source§impl Serialize for Credential
impl Serialize for Credential
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
impl StructuralPartialEq for Credential
Auto Trait Implementations§
impl Freeze for Credential
impl RefUnwindSafe for Credential
impl Send for Credential
impl Sync for Credential
impl Unpin for Credential
impl UnwindSafe for Credential
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more