pub trait VerifyPrimitive<C>:
AffineCoordinates<FieldRepr = FieldBytes<C>>
+ Copy
+ Sized{
// Provided methods
fn verify_prehashed(
&self,
z: &FieldBytes<C>,
sig: &Signature<C>,
) -> Result<()> { ... }
fn verify_digest<D>(&self, msg_digest: D, sig: &Signature<C>) -> Result<()>
where D: FixedOutput<OutputSize = FieldBytesSize<C>> { ... }
}Available on crate features
hazmat and arithmetic only.Expand description
Verify the given prehashed message using ECDSA.
This trait is intended to be implemented on type which can access
the affine point represeting the public key via &self, such as a
particular curve’s AffinePoint type.
Provided Methods§
Sourcefn verify_prehashed(&self, z: &FieldBytes<C>, sig: &Signature<C>) -> Result<()>
fn verify_prehashed(&self, z: &FieldBytes<C>, sig: &Signature<C>) -> Result<()>
Verify the prehashed message against the provided ECDSA signature.
Accepts the following arguments:
z: message digest to be verified. MUST BE OUTPUT OF A CRYPTOGRAPHICALLY SECURE DIGEST ALGORITHM!!!sig: signature to be verified against the key and message
Sourcefn verify_digest<D>(&self, msg_digest: D, sig: &Signature<C>) -> Result<()>where
D: FixedOutput<OutputSize = FieldBytesSize<C>>,
Available on crate feature digest only.
fn verify_digest<D>(&self, msg_digest: D, sig: &Signature<C>) -> Result<()>where
D: FixedOutput<OutputSize = FieldBytesSize<C>>,
digest only.Verify message digest against the provided signature.
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.