pub struct MemoryAuthorizationCodeStore {
entries: RwLock<HashMap<String, AuthorizationCode>>,
}Expand description
The in-process authorization code store.
Fields§
§entries: RwLock<HashMap<String, AuthorizationCode>>Implementations§
Trait Implementations§
Source§impl AuthorizationCodeStore for MemoryAuthorizationCodeStore
impl AuthorizationCodeStore for MemoryAuthorizationCodeStore
Source§fn issue(&self, record: AuthorizationCodeRecord) -> String
fn issue(&self, record: AuthorizationCodeRecord) -> String
Mints and stores a code for a confirmed grant.
Source§fn redeem(&self, code: &str) -> Option<AuthorizationCodeRecord>
fn redeem(&self, code: &str) -> Option<AuthorizationCodeRecord>
Redeems a code. One-shot: RFC 6749 §4.1.2 requires a code be usable
once, and a second presentation of an already-redeemed code is
itself a signal the server treats as
invalid_grant rather than as
“return the same tokens again.”Source§fn revoke_account(&self, did: &str)
fn revoke_account(&self, did: &str)
Drops every unredeemed code this store holds for
did. Read moreSource§impl Debug for MemoryAuthorizationCodeStore
impl Debug for MemoryAuthorizationCodeStore
Source§impl Default for MemoryAuthorizationCodeStore
impl Default for MemoryAuthorizationCodeStore
Source§fn default() -> MemoryAuthorizationCodeStore
fn default() -> MemoryAuthorizationCodeStore
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl !Freeze for MemoryAuthorizationCodeStore
impl RefUnwindSafe for MemoryAuthorizationCodeStore
impl Send for MemoryAuthorizationCodeStore
impl Sync for MemoryAuthorizationCodeStore
impl Unpin for MemoryAuthorizationCodeStore
impl UnsafeUnpin for MemoryAuthorizationCodeStore
impl UnwindSafe for MemoryAuthorizationCodeStore
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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> 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