starknet_crypto

Function verify

Source
pub fn verify(
    public_key: &Felt,
    message: &Felt,
    r: &Felt,
    s: &Felt,
) -> Result<bool, VerifyError>
Expand description

Verifies if a signature is valid over a message hash given a public key. Returns an error instead of false if the public key is invalid.

ยงParameters

  • public_key: The public key.
  • message: The message hash.
  • r: The r value of the signature.
  • s: The s value of the signature.