#[non_exhaustive]pub enum Error {
Encoding(EncodingError),
Key(KeyError),
SecretOutOfRange,
PreSignatureOutOfRange,
InvalidPreSignaturePoint,
SignatureMismatch,
ExtractFailed,
NoRecoveryId,
NonceGenerationFailed,
InvalidPreSignature,
WrongAdaptorSecret,
}Expand description
An adaptor-signature error.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Encoding(EncodingError)
Malformed hex or length.
Key(KeyError)
An invalid key or signature.
SecretOutOfRange
The adaptor secret is zero or not below the curve order.
PreSignatureOutOfRange
The pre-signature’s s' is zero or not below the curve order.
InvalidPreSignaturePoint
The pre-signature’s R is not a valid compressed point.
SignatureMismatch
The signature’s r is not the pre-signature’s.
ExtractFailed
Neither sign of s'·s⁻¹ is the discrete log of the adaptor point.
NoRecoveryId
Neither recovery bit recovers the public key.
NonceGenerationFailed
The RNG failed (try_fill_bytes returned an error) or kept producing unusable nonces (it is broken).
InvalidPreSignature
pre_verify failed: the pre-signature is malformed, or does not complete to a signature by this key on this
digest for this adaptor point.
WrongAdaptorSecret
The adaptor secret is not the discrete log of the pre-signature’s adaptor point.
Trait Implementations§
impl Eq for Error
Source§impl Error for Error
impl Error for Error
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()