Function ecdsa::rfc6979::generate_k
source ·
[−]pub fn generate_k<C, D>(
secret_scalar: &NonZeroScalar<C>,
msg_digest: D,
additional_data: &[u8]
) -> Zeroizing<NonZeroScalar<C>> where
C: ProjectiveArithmetic,
D: FixedOutput<OutputSize = C::FieldSize> + BlockInput + Clone + Default + Reset + Update,
FieldBytes<C>: From<Scalar<C>> + for<'r> From<&'r Scalar<C>>,
Scalar<C>: PrimeField<Repr = FieldBytes<C>> + FromDigest<C> + Invert<Output = Scalar<C>> + Zeroize,
Expand description
Generate ephemeral scalar k
from the secret scalar and a digest of the
input message.