OpenBSD manual page server

Manual Page Search Parameters

DSA_METH_NEW(3) Library Functions Manual DSA_METH_NEW(3)

DSA_meth_new, DSA_meth_free, DSA_meth_dup, DSA_meth_set_sign, DSA_meth_set_finishbuild up DSA methods

#include <openssl/dsa.h>

DSA_METHOD *
DSA_meth_new(const char *name, int flags);

void
DSA_meth_free(DSA_METHOD *meth);

DSA_METHOD *
DSA_meth_dup(const DSA_METHOD *meth);

int
DSA_meth_set_sign(DSA_METHOD *meth, DSA_SIG *(*sign)(const unsigned char *, int, DSA *));

int
DSA_meth_set_finish(DSA_METHOD *meth, int (*finish)(DSA *));

The DSA_METHOD structure holds function pinters for custom DSA implementations.

() creates a new DSA_METHOD structure. A copy of the NUL-terminated name is stored in the new DSA_METHOD object. Any new DSA object constructed from this DSA_METHOD will have the given flags set by default.

() creates a deep copy of meth. This might be useful for creating a new DSA_METHOD based on an existing one, but with some differences.

() destroys meth and frees any memory associated with it.

() sets the function used for creating a DSA signature. This function will be called from DSA_do_sign(3) and indirectly from DSA_sign(3). The parameters of sign have the same meaning as for DSA_do_sign(3).

() sets an optional function for destroying a DSA object. Unless finish is NULL, it will be called from DSA_free(3). It takes the same argument and is intended to do DSA implementation specific cleanup. The memory used by the DSA object itself should not be freed by the finish function.

DSA_meth_new() and DSA_meth_dup() return the newly allocated DSA_METHOD object or NULL on failure.

All DSA_meth_set_*() functions return 1 on success or 0 on failure.

DSA_do_sign(3), DSA_new(3), DSA_set_method(3), DSA_SIG_new(3), DSA_sign(3)

These functions first appeared in OpenSSL 1.1.0 and have been available since OpenBSD 6.3.

March 18, 2018 OpenBSD-6.4