pub enum CreateError {
NotAnIdentityKey(Purpose),
ExpBeyondMaxLifetime {
exp: i64,
now: i64,
max: i64,
},
WindowNeverOpens {
nbf: i64,
exp: i64,
},
Sign(KeyError),
}Expand description
Why create mints no token, naming the values it compared.
Variants§
NotAnIdentityKey(Purpose)
A token is signed by an identity key, and this key is not one.
ExpBeyondMaxLifetime
exp lies more than MAX_LIFETIME past now: at most max.
WindowNeverOpens
nbf is not before exp, so the token would never be valid.
Sign(KeyError)
The issuer’s key could not sign.
Trait Implementations§
Source§impl Clone for CreateError
impl Clone for CreateError
Source§impl Debug for CreateError
impl Debug for CreateError
Source§impl Display for CreateError
impl Display for CreateError
impl Eq for CreateError
Source§impl Error for CreateError
impl Error for CreateError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl PartialEq for CreateError
impl PartialEq for CreateError
impl StructuralPartialEq for CreateError
Auto Trait Implementations§
impl Freeze for CreateError
impl RefUnwindSafe for CreateError
impl Send for CreateError
impl Sync for CreateError
impl Unpin for CreateError
impl UnsafeUnpin for CreateError
impl UnwindSafe for CreateError
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