package hacl-star

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type

Versions of the ECDSA functions which work on low-S normalized signatures. These functions can be used when compatibility with libsecp256k1 is required.

val sign : sk:bytes -> msg:bytes -> k:bytes -> signature:bytes -> bool

sign sk msg k signature attempts to sign the message msg with secret key sk and signing secret k. If successful, the low-S normalized signature is written in signature and the function returns true.

val normalize_signature : signature:bytes -> bool

normalize_signature signature computes the canonical lowest S value of a raw signature in-place. Returns true if successful.