pub trait SignPrimitive<C>{
// Required method
fn try_sign_prehashed<K: Borrow<Scalar<C>> + Invert<Output = Scalar<C>>>(
&self,
ephemeral_scalar: &K,
hashed_msg: &Scalar<C>,
) -> Result<Signature<C>>;
}Expand description
Try to sign the given prehashed message using ECDSA.
This trait is intended to be implemented on a type with access
to the secret scalar via &self, such as particular curve’s Scalar type,
or potentially a key handle to a hardware device.
Required Methods§
Sourcefn try_sign_prehashed<K: Borrow<Scalar<C>> + Invert<Output = Scalar<C>>>(
&self,
ephemeral_scalar: &K,
hashed_msg: &Scalar<C>,
) -> Result<Signature<C>>
fn try_sign_prehashed<K: Borrow<Scalar<C>> + Invert<Output = Scalar<C>>>( &self, ephemeral_scalar: &K, hashed_msg: &Scalar<C>, ) -> Result<Signature<C>>
Try to sign the prehashed message.
Accepts the following arguments:
ephemeral_scalar: ECDSAkvalue. MUST BE UNIFORMLY RANDOM!!!hashed_msg: scalar computed from a hashed message digest to be signed. MUST BE OUTPUT OF A CRYPTOGRAPHICALLY SECURE DIGEST ALGORITHM!!!
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".
Implementors§
impl<C, T> SignPrimitive<C> for Twhere
C: Curve + ProjectiveArithmetic,
T: RecoverableSignPrimitive<C>,
SignatureSize<C>: ArrayLength<u8>,
Available on crate feature
arithmetic only.