starknet_crypto

Function sign

Source
pub fn sign(
    private_key: &Felt,
    message: &Felt,
    k: &Felt,
) -> Result<ExtendedSignature, SignError>
Expand description

Computes ECDSA signature given a Stark private key and message hash.

ยงParameters

  • private_key: The private key.
  • message: The message hash.
  • k: A random k value. You MUST NOT use the same k on different signatures.