musig Nonce Gen
open override fun musigNonceGen(sessionRandom32: ByteArray, privkey: ByteArray?, pubkey: ByteArray, msg32: ByteArray?, keyaggCache: ByteArray?, extraInput32: ByteArray?): ByteArray
Generate a secret nonce to be used in a musig2 signing session. This nonce must never be persisted or reused across signing sessions. All optional arguments exist to enrich the quality of the randomness used, which is critical for security.
Return
serialized version of the secret nonce and the corresponding public nonce.
Parameters
session Random32
unique 32-byte random data that must not be reused to generate other nonces
privkey
(optional) signer's private key.
pubkey
signer's public key
msg32
(optional) 32-byte message that will be signed, if already known.
keyagg Cache
(optional) key aggregation cache data from the signing session.
extra Input32
(optional) additional 32-byte random data.