package octez-libs
Install
Dune Dependency
Authors
Maintainers
Sources
sha256=55ea1fb8bb3273a7fc270ca8f650d45c56449665619482aad9bc12f3ea736b7e
sha512=fec850fc2d17d7490bbabd5147d62aad13b3aaed8774270f8a38ab419670ed03e0fd30cf8642a97984eca5c2446726fe590ad99c015f7ec50919dc7652f25053
doc/octez-libs.bls12-381-signature/Bls12_381_signature/index.html
Module Bls12_381_signature
Source
Follow the BLS signature draft of CFRG, version 4
Type of the secret keys.
The size of a serialized value sk
sk_of_bytes_exn bs
attempts to deserialize bs
into a secret key. bs
must be the little endian representation of the secret key. In this case, secret keys are scalars of BLS12-381 and are encoded on 32 bytes. The bytes sequence might be less of 32 bytes and in this case, the bytes sequence is padded on the right by 0's.
sk_of_bytes_opt bs
is the same than sk_of_bytes_exn
but returns an option instead of an exception.
sk_to_bytes sk
serialises the secret key into the little endian representation.
generate_sk ?key_info ikm
generates a new (random) secret key. ikm
must be at least 32 bytes (otherwise, raise Invalid_argument
). The default value of key_info
is the empty bytes sequence.
BLS signatures instantiation minimizing the size of the public keys (48 bytes) but use longer signatures (96 bytes).