[#BN_generate_dsa_nonce] = BN_generate_dsa_nonce :mrdocs: Generate a DSA/ECDSA per‐signature nonce in [0, ]`range).` == Synopsis Declared in `<openssl/bn.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- int BN_generate_dsa_nonce( xref:BIGNUM.adoc[BIGNUM]* out, xref:BIGNUM.adoc[BIGNUM] const* range, xref:BIGNUM.adoc[BIGNUM] const* priv, unsigned char const* message, size_t message_len, xref:BN_CTX.adoc[BN_CTX]* ctx); ---- == Description Mixes `priv` and `message` with fresh entropy so an RNG failure alone cannot expose the private key the way a raw BN_rand_range() nonce would. == Return Value 1 on success, or 0 on failure. == Parameters [cols="1,4"] |=== | Name| Description | *out* | Destination BIGNUM that receives the nonce k. | *range* | Exclusive upper bound (typically the group order). | *priv* | Private key value mixed into the nonce derivation. | *message* | Message/digest octets mixed into the nonce derivation. | *message_len* | Length of `message` in bytes. | *ctx* | BN_CTX for temporary BIGNUMs, or NULL. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#