Trait oxide_auth::code_grant::Authorizer
[−]
[src]
pub trait Authorizer {
fn authorize(&mut self, _: Request) -> String;
fn extract<'a>(&mut self, _: &'a str) -> Option<Grant<'a>>;
}Authorizers create and manage authorization codes.
The authorization code can be traded for a bearer token at the token endpoint.
Required Methods
Create a code which allows retrieval of a bearer token at a later time.
fn extract<'a>(&mut self, _: &'a str) -> Option<Grant<'a>>
Retrieve the parameters associated with a token, invalidating the code in the process. In particular, a code should not be usable twice (there is no stateless implementation of an authorizer for this reason).
Implementors
impl<I: TokenGenerator> Authorizer for Storage<I>