pub fn rfc6979_generate_k<C, D>(
    x: &NonZeroScalar<C>,
    z: &Scalar<C>,
    ad: &[u8]
) -> Zeroizing<NonZeroScalar<C>>where
    C: PrimeCurve + ProjectiveArithmetic,
    D: FixedOutput<OutputSize = FieldSize<C>> + BlockInput + Clone + Default + Reset + Update,
Expand description

Deterministically compute ECDSA ephemeral scalar k using the method described in RFC6979.

Accepts the following parameters:

  • x: secret key
  • z: message scalar (i.e. message digest reduced mod p)
  • ad: optional additional data, e.g. added entropy from an RNG