#[non_exhaustive]pub enum SignError {
NoSignature,
WrongAlgorithm {
got: String,
},
MalformedKey,
MalformedSignature,
InvalidSignature,
Encoding(String),
RevokedKey {
revoked_at: u64,
time: u64,
},
}Expand description
Errors from crate::sign - commit / operation signing + verification.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
NoSignature
Object carries no signature field; verification requires one.
WrongAlgorithm
Signature field uses an algorithm this implementation doesn’t support.
MalformedKey
Public key is not the expected 32 bytes or fails Ed25519 decode.
MalformedSignature
Signature bytes are not the expected 64 bytes.
InvalidSignature
Ed25519 verify rejected the signature.
Encoding(String)
Re-canonicalising the object for verification failed.
RevokedKey
The signing key is present in the revocation list and the object’s timestamp is strictly after the revocation (SPEC §9.2).
Trait Implementations§
Source§impl Error for SignError
impl Error for SignError
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()
Auto Trait Implementations§
impl Freeze for SignError
impl RefUnwindSafe for SignError
impl Send for SignError
impl Sync for SignError
impl Unpin for SignError
impl UnsafeUnpin for SignError
impl UnwindSafe for SignError
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