pub struct PasskeyAuthenticator { /* private fields */ }
Expand description
A passkey authenticator.
§BCS
The BCS serialized form for this type is defined by the following ABNF:
passkey-bcs = bytes ; where the contents of the bytes are
; defined by <passkey>
passkey = passkey-flag
bytes ; passkey authenticator data
client-data-json ; valid json
simple-signature ; required to be a secp256r1 signature
client-data-json = string ; valid json
See CollectedClientData for
the required json-schema for the client-data-json
rule. In addition, Sui currently requires
that the CollectedClientData.type
field is required to be webauthn.get
.
Note: Due to historical reasons, signatures are serialized slightly different from the majority
of the types in Sui. In particular if a signature is ever embedded in another structure it
generally is serialized as bytes
meaning it has a length prefix that defines the length of
the completely serialized signature.
Implementations§
Source§impl PasskeyAuthenticator
impl PasskeyAuthenticator
Sourcepub fn authenticator_data(&self) -> &[u8] ⓘ
pub fn authenticator_data(&self) -> &[u8] ⓘ
Opaque authenticator data for this passkey signature.
See Authenticator Data for more information on this field.
Sourcepub fn client_data_json(&self) -> &str
pub fn client_data_json(&self) -> &str
Structured, unparsed, JSON for this passkey signature.
See CollectedClientData for more information on this field.
Sourcepub fn challenge(&self) -> &[u8] ⓘ
pub fn challenge(&self) -> &[u8] ⓘ
The parsed challenge message for this passkey signature.
This is parsed by decoding the base64url data from the client_data_json.challenge
field.
Sourcepub fn signature(&self) -> SimpleSignature
pub fn signature(&self) -> SimpleSignature
The passkey signature.
Trait Implementations§
Source§impl Arbitrary for PasskeyAuthenticator
impl Arbitrary for PasskeyAuthenticator
Source§type Parameters = ()
type Parameters = ()
arbitrary_with
accepts for configuration
of the generated Strategy
. Parameters must implement Default
.Source§type Strategy = BoxedStrategy<PasskeyAuthenticator>
type Strategy = BoxedStrategy<PasskeyAuthenticator>
Strategy
used to generate values of type Self
.Source§fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
fn arbitrary_with(_args: Self::Parameters) -> Self::Strategy
Source§impl Clone for PasskeyAuthenticator
impl Clone for PasskeyAuthenticator
Source§fn clone(&self) -> PasskeyAuthenticator
fn clone(&self) -> PasskeyAuthenticator
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for PasskeyAuthenticator
impl Debug for PasskeyAuthenticator
Source§impl<'de> Deserialize<'de> for PasskeyAuthenticator
Available on crate feature serde
only.
impl<'de> Deserialize<'de> for PasskeyAuthenticator
serde
only.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 PasskeyAuthenticator
impl PartialEq for PasskeyAuthenticator
Source§impl Serialize for PasskeyAuthenticator
Available on crate feature serde
only.
impl Serialize for PasskeyAuthenticator
serde
only.