pub struct GetAssertionRequest { /* private fields */ }Expand description
Request for getting an assertion (authenticatorGetAssertion)
Use the builder pattern to construct requests with optional parameters.
Implementations§
Source§impl GetAssertionRequest
impl GetAssertionRequest
Sourcepub fn new(client_data_hash: ClientDataHash, rp_id: impl Into<String>) -> Self
pub fn new(client_data_hash: ClientDataHash, rp_id: impl Into<String>) -> Self
Create a new GetAssertionRequest with required parameters
§Arguments
client_data_hash- SHA-256 hash of the WebAuthn client datarp_id- Relying party identifier (domain)
Sourcepub fn with_credential(self, credential: CredentialDescriptor) -> Self
pub fn with_credential(self, credential: CredentialDescriptor) -> Self
Add a single credential to the allow list
Sourcepub fn with_credentials(self, credentials: Vec<CredentialDescriptor>) -> Self
pub fn with_credentials(self, credentials: Vec<CredentialDescriptor>) -> Self
Set the allow list to a specific set of credentials
Sourcepub fn with_pin_uv_auth(self, auth: PinUvAuth) -> Self
pub fn with_pin_uv_auth(self, auth: PinUvAuth) -> Self
Set the PIN/UV authentication parameter
Sourcepub fn with_timeout(self, timeout_ms: i32) -> Self
pub fn with_timeout(self, timeout_ms: i32) -> Self
Set the timeout in milliseconds (default: 30000ms)
Sourcepub fn with_user_verification(self, user_verification: bool) -> Self
pub fn with_user_verification(self, user_verification: bool) -> Self
Set whether to require user verification
Sourcepub fn client_data_hash(&self) -> &ClientDataHash
pub fn client_data_hash(&self) -> &ClientDataHash
Get the client data hash
Sourcepub fn allow_list(&self) -> &[CredentialDescriptor]
pub fn allow_list(&self) -> &[CredentialDescriptor]
Get the allow list of credentials
Sourcepub fn pin_uv_auth(&self) -> Option<&PinUvAuth>
pub fn pin_uv_auth(&self) -> Option<&PinUvAuth>
Get the PIN/UV authentication parameter if set
Sourcepub fn timeout_ms(&self) -> i32
pub fn timeout_ms(&self) -> i32
Get the timeout in milliseconds
Trait Implementations§
Auto Trait Implementations§
impl Freeze for GetAssertionRequest
impl RefUnwindSafe for GetAssertionRequest
impl Send for GetAssertionRequest
impl Sync for GetAssertionRequest
impl Unpin for GetAssertionRequest
impl UnwindSafe for GetAssertionRequest
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
Mutably borrows from an owned value. Read more