Skip to main content

ClientData

Trait ClientData 

Source
pub trait ClientData<E: Serialize> {
    // Required methods
    fn extra_client_data(&self) -> E;
    fn client_data_hash(&self) -> Option<Vec<u8>>;
}
Expand description

A trait describing how client data should be generated during a WebAuthn operation.

Required Methods§

Source

fn extra_client_data(&self) -> E

Extra client data to be appended to the automatically generated client data.

Source

fn client_data_hash(&self) -> Option<Vec<u8>>

The hash of the client data to be used in the WebAuthn operation.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl ClientData<()> for Option<Vec<u8>>

Backwards compatibility with the previous register and authenticate functions which only took Option<Vec<u8>> as a client data hash.

Implementors§