pub enum OAuth2ErrorCode {
InvalidRequest,
InvalidClient,
InvalidGrant,
UnauthorizedClient,
UnsupportedGrantType,
InvalidScope,
Unrecognized(String),
}
Expand description
OAuth 2.0 error codes.
Variants§
InvalidRequest
The request is missing a required parameter, includes an unsupported parameter value (other than grant type), repeats a parameter, includes multiple credentials, utilizes more than one mechanism for authenticating the client, or is otherwise malformed.
InvalidClient
Client authentication failed (e.g., unknown client, no client authentication included, or unsupported authentication method).
InvalidGrant
The provided authorization grant (e.g., authorization code, resource owner credentials) or refresh token is invalid, expired, revoked, does not match the redirection URI used in the authorization request, or was issued to another client.
The authenticated client is not authorized to use this authorization grant type.
UnsupportedGrantType
The authorization grant type is not supported by the authorization server.
InvalidScope
The requested scope is invalid, unknown, malformed, or exceeds the scope granted by the resource owner.
Unrecognized(String)
An unrecognized error code, not defined in RFC 6749.
Trait Implementations§
Source§impl Clone for OAuth2ErrorCode
impl Clone for OAuth2ErrorCode
Source§fn clone(&self) -> OAuth2ErrorCode
fn clone(&self) -> OAuth2ErrorCode
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for OAuth2ErrorCode
impl Debug for OAuth2ErrorCode
Source§impl<'a> From<&'a str> for OAuth2ErrorCode
impl<'a> From<&'a str> for OAuth2ErrorCode
Source§fn from(s: &str) -> OAuth2ErrorCode
fn from(s: &str) -> OAuth2ErrorCode
Source§impl PartialEq for OAuth2ErrorCode
impl PartialEq for OAuth2ErrorCode
impl Eq for OAuth2ErrorCode
impl StructuralPartialEq for OAuth2ErrorCode
Auto Trait Implementations§
impl Freeze for OAuth2ErrorCode
impl RefUnwindSafe for OAuth2ErrorCode
impl Send for OAuth2ErrorCode
impl Sync for OAuth2ErrorCode
impl Unpin for OAuth2ErrorCode
impl UnwindSafe for OAuth2ErrorCode
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.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>
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>
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