[−][src]Struct orizentic::VerifiedToken
An VerifiedToken is a combination of the JWT serialization and the decoded ClaimSet
. This will
only be created by the validate_function
, and thus will represent a token which has been
validated via signature, expiration time, and presence in the database.
Fields
text: String
claims: ClaimSet
Methods
impl VerifiedToken
[src]
pub fn check_authorizations<F: FnOnce(&ResourceName, &Permissions) -> bool>(
&self,
f: F
) -> bool
[src]
&self,
f: F
) -> bool
Given a VerifiedToken
, pass the resource name and permissions to a user-defined function. The
function should return true if the caller should be granted access to the resource and false,
otherwise. That result will be passed back to the caller.
Trait Implementations
Auto Trait Implementations
impl Unpin for VerifiedToken
impl Sync for VerifiedToken
impl Send for VerifiedToken
impl RefUnwindSafe for VerifiedToken
impl UnwindSafe for VerifiedToken
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,