pub struct AuthClient<'a> {
pub(crate) client: &'a Client,
}
Fields§
§client: &'a Client
Implementations§
Source§impl<'a> AuthClient<'a>
impl<'a> AuthClient<'a>
pub async fn renew_token(&self) -> Result<(), Error>
pub async fn login_access_token( &self, input: &AccessTokenLoginRequest, ) -> Result<AccessTokenLoginResponse, Error>
Source§impl<'a> AuthClient<'a>
impl<'a> AuthClient<'a>
pub fn password_strength( &self, password: String, email: String, additional_inputs: Vec<String>, ) -> u8
pub fn satisfies_policy( &self, password: String, strength: u8, policy: &MasterPasswordPolicyOptions, ) -> bool
pub fn make_register_keys( &self, email: String, password: String, kdf: Kdf, ) -> Result<RegisterKeyResponse, Error>
pub fn make_register_tde_keys( &self, email: String, org_public_key: String, remember_device: bool, ) -> Result<RegisterTdeKeyResponse, Error>
pub fn make_key_connector_keys( &self, ) -> Result<KeyConnectorResponse, CryptoError>
pub async fn register(&self, input: &RegisterRequest) -> Result<(), Error>
pub async fn prelogin(&self, email: String) -> Result<Kdf, Error>
pub async fn login_password( &self, input: &PasswordLoginRequest, ) -> Result<PasswordLoginResponse, Error>
pub async fn login_api_key( &self, input: &ApiKeyLoginRequest, ) -> Result<ApiKeyLoginResponse, Error>
pub async fn send_two_factor_email( &self, tf: &TwoFactorEmailRequest, ) -> Result<(), Error>
pub fn validate_password( &self, password: String, password_hash: String, ) -> Result<bool, Error>
pub fn validate_password_user_key( &self, password: String, encrypted_user_key: String, ) -> Result<String, Error>
pub fn validate_pin( &self, pin: String, pin_protected_user_key: EncString, ) -> Result<bool, Error>
pub fn new_auth_request( &self, email: &str, ) -> Result<AuthRequestResponse, Error>
pub fn approve_auth_request( &self, public_key: String, ) -> Result<AsymmetricEncString, Error>
pub fn trust_device(&self) -> Result<TrustDeviceResponse, Error>
Source§impl<'a> AuthClient<'a>
impl<'a> AuthClient<'a>
pub async fn login_device( &self, email: String, device_identifier: String, ) -> Result<NewAuthRequestResponse, Error>
pub async fn login_device_complete( &self, auth_req: NewAuthRequestResponse, ) -> Result<(), Error>
Auto Trait Implementations§
impl<'a> Freeze for AuthClient<'a>
impl<'a> !RefUnwindSafe for AuthClient<'a>
impl<'a> Send for AuthClient<'a>
impl<'a> Sync for AuthClient<'a>
impl<'a> Unpin for AuthClient<'a>
impl<'a> !UnwindSafe for AuthClient<'a>
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
§impl<T> CompatExt for T
impl<T> CompatExt for T
§impl<T, UT> HandleAlloc<UT> for T
impl<T, UT> HandleAlloc<UT> for T
§fn new_handle(value: Arc<T>) -> Handle
fn new_handle(value: Arc<T>) -> Handle
Create a new handle for an Arc value Read more
§unsafe fn clone_handle(handle: Handle) -> Handle
unsafe fn clone_handle(handle: Handle) -> Handle
Clone a handle Read more
§unsafe fn consume_handle(handle: Handle) -> Arc<T>
unsafe fn consume_handle(handle: Handle) -> Arc<T>
Consume a handle, getting back the initial
Arc<>
Read more§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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>
Converts
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>
Converts
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