pub struct ServiceToken {
pub token_id: String,
pub principal: String,
pub scopes: Vec<String>,
pub secret_hash_phc: String,
pub expires_unix: u64,
}Expand description
Service token metadata. The raw bearer secret is never stored.
Fields§
§token_id: String§principal: String§scopes: Vec<String>§secret_hash_phc: StringArgon2id PHC string with a unique random salt.
expires_unix: u64Implementations§
Trait Implementations§
Source§impl Clone for ServiceToken
impl Clone for ServiceToken
Source§fn clone(&self) -> ServiceToken
fn clone(&self) -> ServiceToken
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ServiceToken
impl Debug for ServiceToken
Source§impl<'de> Deserialize<'de> for ServiceToken
impl<'de> Deserialize<'de> for ServiceToken
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>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for ServiceToken
Source§impl PartialEq for ServiceToken
impl PartialEq for ServiceToken
Source§impl Serialize for ServiceToken
impl Serialize for ServiceToken
impl StructuralPartialEq for ServiceToken
Auto Trait Implementations§
impl Freeze for ServiceToken
impl RefUnwindSafe for ServiceToken
impl Send for ServiceToken
impl Sync for ServiceToken
impl Unpin for ServiceToken
impl UnsafeUnpin for ServiceToken
impl UnwindSafe for ServiceToken
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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