DSA_sign

Create a DER-encoded DSA signature over a message digest (deprecated).

Synopsis

Declared in <openssl/dsa.h>

[[deprecated]]
int
DSA_sign(
    int type,
    unsigned char const* dgst,
    int dlen,
    unsigned char* sig,
    unsigned int* siglen,
    DSA* dsa);

WARNING

Deprecated. Use of this entity is allowed but discouraged.

Return Value

1 on success, or 0 on failure.

Parameters

NameDescription
typeHistorical digest NID; ignored by modern implementations.
dgstDigest octets to sign.
dlenLength of dgst in bytes.
sigOutput buffer receiving the DER signature (at least DSA_size(dsa) bytes).
siglenReceives the number of signature bytes written.
dsaDSA key containing the private key used for signing.