DSA_SET_METHOD(3ossl)
π NAME π
DSA_set_default_method, DSA_get_default_method, DSA_set_method, DSA_new_method, DSA_OpenSSL β select DSA method π
This is the DSA_SET_METHOD(3ossl) page from the OpenSSL manuals, and yes bestie, it's a whole vibe π
β¨ SYNOPSIS β¨
#include <openssl/dsa.h>
β οΈ Heads up: the following functions have been deprecated since OpenSSL 3.0, and can be hidden entirely by definingOPENSSL_API_COMPATwith a suitable version value, seeopenssl_user_macros(7):
void DSA_set_default_method(const DSA_METHOD *meth);
const DSA_METHOD *DSA_get_default_method(void);
int DSA_set_method(DSA *dsa, const DSA_METHOD *meth);
DSA *DSA_new_method(ENGINE *engine);
const DSA_METHOD *DSA_OpenSSL(void);
πΈ DESCRIPTION πΈ
okay so all of the functions described on this page are deprecated. Applications should providers instead of method overrides. π that's the whole mood of this page, fr fr.
A DSA_METHOD specifies the functions that OpenSSL uses for DSA operations. By modifying the method, alternative implementations such as hardware accelerators may be used.
π¨ IMPORTANT: See the NOTES section for important information about how these DSA API functions are affected by the use of ENGINE API calls.
Initially, the default DSA_METHOD is the OpenSSL internal implementation, as returned by DSA_OpenSSL(). π«Ά
DSA_set_default_method()β makes meth the default method for all DSA structures created later. NB: this is true only whilst noENGINEhas been set as a default for DSA, so this function is no longer recommended. Also it is not thread-safe and should not be called at the same time as other OpenSSL functions. not the moment bestie πDSA_get_default_method()β returns a pointer to the current defaultDSA_METHOD. However, the meaningfulness of this result is dependent on whether theENGINEAPI is being used, so this function is no longer recommended either. πDSA_set_method()β selects meth to perform all operations using the keyrsa. This will replace theDSA_METHODused by the DSA key, and if the previous method was supplied by anENGINE, the handle to thatENGINEwill be released during the change. It is possible to have DSA keys that only work with certainDSA_METHODimplementations (e.g. from anENGINEmodule that supports embedded hardware-protected keys), and in such cases attempting to change theDSA_METHODfor the key can have unexpected results. SeeDSA_meth_new(3)for information on constructing customDSA_METHODobjects;DSA_new_method()β allocates and initializes aDSAstructure so that engine will be used for the DSA operations. If engine isNULL, the default engine for DSA operations is used, and if no defaultENGINEis set, theDSA_METHODcontrolled byDSA_set_default_method()is used. β¨
π¦ RETURN VALUES π¦
DSA_OpenSSL()andDSA_get_default_method()return pointers to the respectiveDSA_METHODs. πDSA_set_default_method()returns no value. literally nothing, it's giving silence πDSA_set_method()returns nonzero if the provided meth was successfully set as the method for dsa (including unloading theENGINEhandle if the previous method was supplied by anENGINE).DSA_new_method()returnsNULLand sets an error code that can be obtained byERR_get_error(3)if the allocation fails. Otherwise it returns a pointer to the newly allocated structure. π«Ά
π SEE ALSO π
DSA_new(3), DSA_new(3), DSA_meth_new(3)
(yes, DSA_new(3) is listed twice and we are respecting the original's choices, periodt π
)
β HISTORY β
All of these functions were deprecated in OpenSSL 3.0. π the end of an era.
π COPYRIGHT π
Copyright 2000-2021 The OpenSSL Project Authors. All Rights Reserved.
Licensed under the Apache License 2.0 (the "License"). You may not use this file except in compliance with the License. You can obtain a copy in the file LICENSE in the source distribution or at
https://www.openssl.org/source/license.html
and that's the whole page bestie!! π§π this was OpenSSL 3.5.9, dated 2026-09-29 β slay, stay deprecated, and go use providers instead π«Άβ¨
π¦ where this page comes from
- fedora 43: openssl-devel 1:3.5.9-1.fc43 Β· Apache-2.0
- fedora 43: openssl-devel 1:3.5.9-1.fc43 Β· Apache-2.0
- fedora 44: openssl-devel 1:3.5.9-1.fc44 Β· Apache-2.0
- fedora 44: openssl-devel 1:3.5.9-1.fc44 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms