pub trait Curve {
type PublicKey;
type Signature;
type Message: AsRef<[u8]> + ?Sized;
type VerifyingKey;
// Required method
fn verify(
signature: &Self::Signature,
message: &Self::Message,
verifying_key: &Self::VerifyingKey,
) -> Option<Self::PublicKey>;
}
Required Associated Types§
type PublicKey
type Signature
Sourcetype VerifyingKey
type VerifyingKey
Public key that should be known prior to verification
Required Methods§
fn verify( signature: &Self::Signature, message: &Self::Message, verifying_key: &Self::VerifyingKey, ) -> Option<Self::PublicKey>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.