summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto
diff options
context:
space:
mode:
authorschwarze <>2025-06-09 12:43:53 +0000
committerschwarze <>2025-06-09 12:43:53 +0000
commit32b60effa89c7fa97c04b7e9e8e6b1304d3a4ad3 (patch)
tree9fc9332adb5e1c9914a47453e24d14e40e5cd765 /src/lib/libcrypto
parent0f2ff66f233cd2c66afdc89bc6e649d3333a8ccd (diff)
downloadopenbsd-32b60effa89c7fa97c04b7e9e8e6b1304d3a4ad3.tar.gz
openbsd-32b60effa89c7fa97c04b7e9e8e6b1304d3a4ad3.tar.bz2
openbsd-32b60effa89c7fa97c04b7e9e8e6b1304d3a4ad3.zip
Retire the manual pages OPENSSL_load_builtin_modules(3) and OBJ_NAME_add(3)
because these functions no longer exist. OK tb@
Diffstat (limited to 'src/lib/libcrypto')
-rw-r--r--src/lib/libcrypto/man/CONF_modules_load_file.314
-rw-r--r--src/lib/libcrypto/man/Makefile4
-rw-r--r--src/lib/libcrypto/man/OBJ_NAME_add.3307
-rw-r--r--src/lib/libcrypto/man/OPENSSL_config.311
-rw-r--r--src/lib/libcrypto/man/OPENSSL_init_crypto.310
-rw-r--r--src/lib/libcrypto/man/OPENSSL_load_builtin_modules.3101
-rw-r--r--src/lib/libcrypto/man/OpenSSL_add_all_algorithms.334
7 files changed, 25 insertions, 456 deletions
diff --git a/src/lib/libcrypto/man/CONF_modules_load_file.3 b/src/lib/libcrypto/man/CONF_modules_load_file.3
index 50fa6a9801..78cfc32f0d 100644
--- a/src/lib/libcrypto/man/CONF_modules_load_file.3
+++ b/src/lib/libcrypto/man/CONF_modules_load_file.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: CONF_modules_load_file.3,v 1.15 2025/06/08 22:40:29 schwarze Exp $ 1.\" $OpenBSD: CONF_modules_load_file.3,v 1.16 2025/06/09 12:43:53 schwarze Exp $
2.\" full merge up to: e9b77246 Jan 20 19:58:49 2017 +0100 2.\" full merge up to: e9b77246 Jan 20 19:58:49 2017 +0100
3.\" selective merge up to: d090fc00 Feb 26 13:11:10 2019 +0800 3.\" selective merge up to: d090fc00 Feb 26 13:11:10 2019 +0800
4.\" 4.\"
@@ -66,7 +66,7 @@
66.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 66.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
67.\" OF THE POSSIBILITY OF SUCH DAMAGE. 67.\" OF THE POSSIBILITY OF SUCH DAMAGE.
68.\" 68.\"
69.Dd $Mdocdate: June 8 2025 $ 69.Dd $Mdocdate: June 9 2025 $
70.Dt CONF_MODULES_LOAD_FILE 3 70.Dt CONF_MODULES_LOAD_FILE 3
71.Os 71.Os
72.Sh NAME 72.Sh NAME
@@ -223,7 +223,6 @@ Load custom configuration file and section instead of the standard one,
223only print warnings on error, missing configuration file ignored: 223only print warnings on error, missing configuration file ignored:
224.Bd -literal 224.Bd -literal
225OPENSSL_no_config(); 225OPENSSL_no_config();
226OPENSSL_load_builtin_modules();
227if (CONF_modules_load_file("/something/app.cnf", "myapp", 226if (CONF_modules_load_file("/something/app.cnf", "myapp",
228 CONF_MFLAGS_IGNORE_MISSING_FILE) <= 0) { 227 CONF_MFLAGS_IGNORE_MISSING_FILE) <= 0) {
229 fprintf(stderr, "WARNING: error loading configuration file\en"); 228 fprintf(stderr, "WARNING: error loading configuration file\en");
@@ -234,11 +233,7 @@ if (CONF_modules_load_file("/something/app.cnf", "myapp",
234In the previous example, the call to 233In the previous example, the call to
235.Xr OPENSSL_no_config 3 234.Xr OPENSSL_no_config 3
236is required first to suppress automatic loading 235is required first to suppress automatic loading
237of the standard configuration file, and the call to 236of the standard configuration file.
238.Xr OPENSSL_load_builtin_modules 3
239is needed so that the configuration of builtin modules
240is loaded in addition to the configuration of
241.Qq myapp .
242.Pp 237.Pp
243Load and parse configuration file manually, custom error handling: 238Load and parse configuration file manually, custom error handling:
244.Bd -literal 239.Bd -literal
@@ -269,8 +264,7 @@ if (fp == NULL) {
269.Sh SEE ALSO 264.Sh SEE ALSO
270.Xr CONF_modules_free 3 , 265.Xr CONF_modules_free 3 ,
271.Xr ERR 3 , 266.Xr ERR 3 ,
272.Xr OPENSSL_config 3 , 267.Xr OPENSSL_config 3
273.Xr OPENSSL_load_builtin_modules 3
274.Sh HISTORY 268.Sh HISTORY
275.Fn X509_get_default_cert_area 269.Fn X509_get_default_cert_area
276first appeared in SSLeay 0.4.1 and has been available since 270first appeared in SSLeay 0.4.1 and has been available since
diff --git a/src/lib/libcrypto/man/Makefile b/src/lib/libcrypto/man/Makefile
index b8dfe86d49..d026643e9d 100644
--- a/src/lib/libcrypto/man/Makefile
+++ b/src/lib/libcrypto/man/Makefile
@@ -1,4 +1,4 @@
1# $OpenBSD: Makefile,v 1.308 2025/04/25 19:57:12 tb Exp $ 1# $OpenBSD: Makefile,v 1.309 2025/06/09 12:43:53 schwarze Exp $
2 2
3.include <bsd.own.mk> 3.include <bsd.own.mk>
4 4
@@ -216,7 +216,6 @@ MAN= \
216 IPAddressRange_new.3 \ 216 IPAddressRange_new.3 \
217 MD5.3 \ 217 MD5.3 \
218 NAME_CONSTRAINTS_new.3 \ 218 NAME_CONSTRAINTS_new.3 \
219 OBJ_NAME_add.3 \
220 OBJ_create.3 \ 219 OBJ_create.3 \
221 OBJ_find_sigid_algs.3 \ 220 OBJ_find_sigid_algs.3 \
222 OBJ_nid2obj.3 \ 221 OBJ_nid2obj.3 \
@@ -232,7 +231,6 @@ MAN= \
232 OPENSSL_cleanse.3 \ 231 OPENSSL_cleanse.3 \
233 OPENSSL_config.3 \ 232 OPENSSL_config.3 \
234 OPENSSL_init_crypto.3 \ 233 OPENSSL_init_crypto.3 \
235 OPENSSL_load_builtin_modules.3 \
236 OPENSSL_malloc.3 \ 234 OPENSSL_malloc.3 \
237 OPENSSL_sk_new.3 \ 235 OPENSSL_sk_new.3 \
238 OpenSSL_add_all_algorithms.3 \ 236 OpenSSL_add_all_algorithms.3 \
diff --git a/src/lib/libcrypto/man/OBJ_NAME_add.3 b/src/lib/libcrypto/man/OBJ_NAME_add.3
deleted file mode 100644
index 0b46010c49..0000000000
--- a/src/lib/libcrypto/man/OBJ_NAME_add.3
+++ /dev/null
@@ -1,307 +0,0 @@
1.\" $OpenBSD: OBJ_NAME_add.3,v 1.6 2024/01/31 08:02:53 tb Exp $
2.\"
3.\" Copyright (c) 2021 Ingo Schwarze <schwarze@openbsd.org>
4.\"
5.\" Permission to use, copy, modify, and distribute this software for any
6.\" purpose with or without fee is hereby granted, provided that the above
7.\" copyright notice and this permission notice appear in all copies.
8.\"
9.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
10.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
11.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
12.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
13.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
14.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
15.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
16.\"
17.Dd $Mdocdate: January 31 2024 $
18.Dt OBJ_NAME_ADD 3
19.Os
20.Sh NAME
21.Nm OBJ_NAME_add ,
22.Nm OBJ_NAME_remove ,
23.Nm OBJ_NAME_get ,
24.Nm OBJ_NAME_new_index ,
25.Nm OBJ_NAME_init ,
26.Nm OBJ_NAME_cleanup
27.Nd global associative array
28.Sh SYNOPSIS
29.In openssl/objects.h
30.Ft int
31.Fo OBJ_NAME_add
32.Fa "const char *name"
33.Fa "int type"
34.Fa "const char *value"
35.Fc
36.Ft int
37.Fo OBJ_NAME_remove
38.Fa "const char *name"
39.Fa "int type"
40.Fc
41.Ft const char *
42.Fo OBJ_NAME_get
43.Fa "const char *name"
44.Fa "int type"
45.Fc
46.Ft int
47.Fo OBJ_NAME_new_index
48.Fa "unsigned long (*hash_func)(const char *name)"
49.Fa "int (*cmp_func)(const char *name1, const char *name2)"
50.Fa "void (*free_func)(const char *name, int type, const char *value)"
51.Fc
52.Ft int
53.Fn OBJ_NAME_init void
54.Ft void
55.Fn OBJ_NAME_cleanup "int type"
56.Bd -literal
57typedef struct {
58 int type;
59 int alias;
60 const char *name;
61 const char *data;
62} OBJ_NAME;
63.Ed
64.Sh DESCRIPTION
65These functions implement a single, static associative array
66with the following properties:
67.Bl -bullet
68.It
69The keys are ordered pairs consisting of a NUL-terminated string
70.Pq called the Fa name
71and an
72.Vt int
73number
74.Pq called the Fa type .
75Two types are predefined and used internally by the library:
76.Dv OBJ_NAME_TYPE_MD_METH
77and
78.Dv OBJ_NAME_TYPE_CIPHER_METH .
79Two additional types are predefined but not used internally:
80.Dv OBJ_NAME_TYPE_PKEY_METH
81and
82.Dv OBJ_NAME_TYPE_COMP_METH .
83All predefined types are greater than
84.Dv OBJ_NAME_TYPE_UNDEF
85and smaller than
86.Dv OBJ_NAME_TYPE_NUM .
87.It
88The values are pointers.
89Formally, they are of the type
90.Vt const char * ,
91but in practice, pointers of other types, for example
92.Vt EVP_CIPHER *
93or
94.Vt EVP_MD * ,
95are often stored as values
96and cast back to the correct type on retrieval.
97.It
98The array supports type-specific aliases for names.
99.El
100.Pp
101.Fn OBJ_NAME_add
102removes the key-value pair or alias with the key
103.Pq Fa name , type
104in the same way as
105.Fn OBJ_NAME_remove
106and inserts a key-value pair with the specified
107.Fa name ,
108.Fa type ,
109and
110.Fa value .
111If the bit
112.Dv OBJ_NAME_ALIAS
113is set in the
114.Fa type
115argument, that bit is cleared before using the
116.Fa type
117and the key
118.Pq Fa name , type
119becomes an alias for the key
120.Pq Fa value , type
121instead of setting a value.
122It is not checked whether the key
123.Pq Fa value , type
124already exists.
125Consequently, it is possible to define an alias
126before setting the associated value.
127.Pp
128.Fn OBJ_NAME_remove
129removes the key-value pair or alias with the key
130.Pq Fa name , type
131from the array, if it exists.
132Otherwise, it has no effect.
133If the bit
134.Dv OBJ_NAME_ALIAS
135is set in the
136.Fa type
137argument, it is ignored and cleared before using the
138.Fa type .
139If the
140.Fa type
141is an application-defined type added with
142.Fn OBJ_NAME_new_index
143and the
144.Fa free_func
145associated with the
146.Fa type
147is not a
148.Dv NULL
149pointer, it is called with the
150.Fa name ,
151.Fa type ,
152and
153.Fa value
154of the key-value pair being removed or with the
155.Fa name ,
156.Fa type ,
157and alias target name of the alias being removed.
158In typical usage, this function might free the
159.Fa name ,
160and it might free the
161.Fa value
162in a type-specific way.
163.Pp
164.Fn OBJ_NAME_get
165looks up the key
166.Pq Fa name , type ,
167recursively resolving up to ten aliases if needed.
168If the bit
169.Dv OBJ_NAME_ALIAS
170is set in the
171.Fa type
172argument, it is cleared before using the
173.Fa type ,
174processing of aliases is disabled, and if
175.Pq Fa name , type
176is an alias, the target name of the alias is returned instead of a value.
177.Pp
178.Fn OBJ_NAME_new_index
179assigns the smallest unassigned positive integer number
180to represent a new, application-defined
181.Fa type .
182The three function pointers will be used, respectively,
183to hash a name for this type, to compare two names for this type,
184and to free the contents of a key-value pair holding the given
185.Fa name ,
186.Fa type ,
187and
188.Fa value .
189If the
190.Fa hash_func
191argument is a
192.Dv NULL
193pointer,
194.Xr lh_strhash 3
195is used instead.
196If the
197.Fa cmp_func
198argument is a
199.Dv NULL
200pointer,
201.Xr strcmp 3
202is used instead.
203If the
204.Fa free_func
205argument is a
206.Dv NULL
207pointer, the
208.Fa name
209and
210.Fa value
211pointers contained in the key-value pair are not freed,
212only the structure representing the pair itself is.
213This default behaviour is also used for the built-in types.
214.Pp
215.Fn OBJ_NAME_init
216initializes the array.
217After initialization, the array is empty.
218Calling
219.Fn OBJ_NAME_init
220when the array is already initialized has no effect.
221Application programs do not need to call this function because
222.Fn OBJ_NAME_add
223and
224.Fn OBJ_NAME_get
225automatically call it whenever needed.
226.Pp
227.Fn OBJ_NAME_cleanup
228removes all key-value pairs and aliases of the given
229.Fa type
230from the array by calling
231.Fn OBJ_NAME_remove
232on every such pair and alias.
233If the
234.Fa type
235argument is negative, it removes all key-value pairs and aliases
236of any type and also reverses all effects of
237.Fn OBJ_NAME_new_index
238and
239.Fn OBJ_NAME_init ,
240in particular resetting the list of types to the predefined types
241and releasing all memory reserved by these functions.
242.Pp
243The
244.Vt OBJ_NAME
245structure represents one key-value pair or one alias with the key
246.Pq Fa name , type .
247If the
248.Fa alias
249field is 0, the
250.Fa data
251field contains the value; otherwise, it contains the alias target name.
252.Sh RETURN VALUES
253.Fn OBJ_NAME_add
254and
255.Fn OBJ_NAME_init
256return 1 on success or 0 if memory allocation fails.
257.Pp
258.Fn OBJ_NAME_remove
259returns 1 if one key-value pair or alias was removed or 0 otherwise.
260.Pp
261.Fn OBJ_NAME_get
262returns the
263.Fa value
264associated with the key
265.Pq Fa name , type
266or
267.Dv NULL
268if
269.Fa name
270is
271.Dv NULL ,
272if the array does not contain a value for this key,
273or if more than ten aliases are encountered before finding a value.
274.Pp
275.Fn OBJ_NAME_new_index
276returns a positive integer greater than or equal to
277.Dv OBJ_NAME_TYPE_NUM
278representing the new type or 0 if memory allocation fails.
279.Sh SEE ALSO
280.Xr EVP_cleanup 3 ,
281.Xr EVP_get_cipherbyname 3 ,
282.Xr EVP_get_digestbyname 3 ,
283.Xr lh_new 3 ,
284.Xr OBJ_create 3 ,
285.Xr OBJ_nid2obj 3
286.Sh BUGS
287Calling
288.Fn OBJ_NAME_get
289with the bit
290.Dv OBJ_NAME_ALIAS
291is not very useful because there is no way to tell
292whether the returned pointer points to a value or to a name,
293short of calling the function again without setting the bit
294and comparing the two returned pointers.
295.Pp
296The
297.Fa free_func
298has no way to tell whether its
299.Fa value
300argument is indeed of the given
301.Fa type
302or whether it is merely the target name of an alias.
303Consequently, to use values of a type
304that requires more cleanup than merely calling
305.Xr free 3
306on it, instances of the type need to begin with a magic number or string
307that cannot occur at the beginning of a name.
diff --git a/src/lib/libcrypto/man/OPENSSL_config.3 b/src/lib/libcrypto/man/OPENSSL_config.3
index 6af0ae0dcb..e21b9817de 100644
--- a/src/lib/libcrypto/man/OPENSSL_config.3
+++ b/src/lib/libcrypto/man/OPENSSL_config.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: OPENSSL_config.3,v 1.17 2025/06/08 22:40:30 schwarze Exp $ 1.\" $OpenBSD: OPENSSL_config.3,v 1.18 2025/06/09 12:43:53 schwarze Exp $
2.\" full merge up to: OpenSSL b97fdb57 Nov 11 09:33:09 2016 +0100 2.\" full merge up to: OpenSSL b97fdb57 Nov 11 09:33:09 2016 +0100
3.\" 3.\"
4.\" This file is a derived work. 4.\" This file is a derived work.
@@ -65,7 +65,7 @@
65.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 65.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
66.\" OF THE POSSIBILITY OF SUCH DAMAGE. 66.\" OF THE POSSIBILITY OF SUCH DAMAGE.
67.\" 67.\"
68.Dd $Mdocdate: June 8 2025 $ 68.Dd $Mdocdate: June 9 2025 $
69.Dt OPENSSL_CONFIG 3 69.Dt OPENSSL_CONFIG 3
70.Os 70.Os
71.Sh NAME 71.Sh NAME
@@ -118,13 +118,11 @@ To use a non-standard configuration file, refer to
118Internally, 118Internally,
119.Fn OPENSSL_config 119.Fn OPENSSL_config
120calls 120calls
121.Xr OPENSSL_init_crypto 3 121.Xr OPENSSL_init_crypto 3 .
122and
123.Xr OPENSSL_load_builtin_modules 3 .
124.Pp 122.Pp
125If an application is compiled with the preprocessor symbol 123If an application is compiled with the preprocessor symbol
126.Dv OPENSSL_LOAD_CONF 124.Dv OPENSSL_LOAD_CONF
127#define'd, 125defined,
128.Xr OpenSSL_add_all_algorithms 3 126.Xr OpenSSL_add_all_algorithms 3
129automatically calls 127automatically calls
130.Fn OPENSSL_config . 128.Fn OPENSSL_config .
@@ -141,7 +139,6 @@ standard configuration file
141.Xr CONF_modules_free 3 , 139.Xr CONF_modules_free 3 ,
142.Xr CONF_modules_load_file 3 , 140.Xr CONF_modules_load_file 3 ,
143.Xr crypto 3 , 141.Xr crypto 3 ,
144.Xr OPENSSL_load_builtin_modules 3 ,
145.Xr OPENSSL_VERSION_NUMBER 3 , 142.Xr OPENSSL_VERSION_NUMBER 3 ,
146.Xr openssl.cnf 5 , 143.Xr openssl.cnf 5 ,
147.Xr x509v3.cnf 5 144.Xr x509v3.cnf 5
diff --git a/src/lib/libcrypto/man/OPENSSL_init_crypto.3 b/src/lib/libcrypto/man/OPENSSL_init_crypto.3
index 72a3059c8d..5c29d55aa9 100644
--- a/src/lib/libcrypto/man/OPENSSL_init_crypto.3
+++ b/src/lib/libcrypto/man/OPENSSL_init_crypto.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: OPENSSL_init_crypto.3,v 1.6 2025/06/08 22:40:30 schwarze Exp $ 1.\" $OpenBSD: OPENSSL_init_crypto.3,v 1.7 2025/06/09 12:43:53 schwarze Exp $
2.\" Copyright (c) 2018, 2020 Ingo Schwarze <schwarze@openbsd.org> 2.\" Copyright (c) 2018, 2020 Ingo Schwarze <schwarze@openbsd.org>
3.\" 3.\"
4.\" Permission to use, copy, modify, and distribute this software for any 4.\" Permission to use, copy, modify, and distribute this software for any
@@ -13,7 +13,7 @@
13.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 13.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
14.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 14.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15.\" 15.\"
16.Dd $Mdocdate: June 8 2025 $ 16.Dd $Mdocdate: June 9 2025 $
17.Dt OPENSSL_INIT_CRYPTO 3 17.Dt OPENSSL_INIT_CRYPTO 3
18.Os 18.Os
19.Sh NAME 19.Sh NAME
@@ -55,10 +55,7 @@ If
55is called before any other crypto or ssl functions, the crypto 55is called before any other crypto or ssl functions, the crypto
56library is initialised by allocating various internal resources, 56library is initialised by allocating various internal resources,
57in particular calling 57in particular calling
58.Xr ERR_load_crypto_strings 3 , 58.Xr ERR_load_crypto_strings 3 .
59.Xr OpenSSL_add_all_ciphers 3 ,
60and
61.Xr OpenSSL_add_all_digests 3 .
62.Pp 59.Pp
63The following 60The following
64.Fa options 61.Fa options
@@ -93,7 +90,6 @@ is intended to return 1 on success or 0 on error.
93.Sh SEE ALSO 90.Sh SEE ALSO
94.Xr CONF_modules_load_file 3 , 91.Xr CONF_modules_load_file 3 ,
95.Xr OPENSSL_config 3 , 92.Xr OPENSSL_config 3 ,
96.Xr OPENSSL_load_builtin_modules 3 ,
97.Xr openssl.cnf 5 93.Xr openssl.cnf 5
98.Sh HISTORY 94.Sh HISTORY
99.Fn OPENSSL_init 95.Fn OPENSSL_init
diff --git a/src/lib/libcrypto/man/OPENSSL_load_builtin_modules.3 b/src/lib/libcrypto/man/OPENSSL_load_builtin_modules.3
deleted file mode 100644
index 2b20efaf0e..0000000000
--- a/src/lib/libcrypto/man/OPENSSL_load_builtin_modules.3
+++ /dev/null
@@ -1,101 +0,0 @@
1.\" $OpenBSD: OPENSSL_load_builtin_modules.3,v 1.8 2023/12/05 02:41:13 jsg Exp $
2.\" OpenSSL b97fdb57 Nov 11 09:33:09 2016 +0100
3.\"
4.\" This file was written by Dr. Stephen Henson <steve@openssl.org>.
5.\" Copyright (c) 2004, 2013 The OpenSSL Project. All rights reserved.
6.\"
7.\" Redistribution and use in source and binary forms, with or without
8.\" modification, are permitted provided that the following conditions
9.\" are met:
10.\"
11.\" 1. Redistributions of source code must retain the above copyright
12.\" notice, this list of conditions and the following disclaimer.
13.\"
14.\" 2. Redistributions in binary form must reproduce the above copyright
15.\" notice, this list of conditions and the following disclaimer in
16.\" the documentation and/or other materials provided with the
17.\" distribution.
18.\"
19.\" 3. All advertising materials mentioning features or use of this
20.\" software must display the following acknowledgment:
21.\" "This product includes software developed by the OpenSSL Project
22.\" for use in the OpenSSL Toolkit. (http://www.openssl.org/)"
23.\"
24.\" 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to
25.\" endorse or promote products derived from this software without
26.\" prior written permission. For written permission, please contact
27.\" openssl-core@openssl.org.
28.\"
29.\" 5. Products derived from this software may not be called "OpenSSL"
30.\" nor may "OpenSSL" appear in their names without prior written
31.\" permission of the OpenSSL Project.
32.\"
33.\" 6. Redistributions of any form whatsoever must retain the following
34.\" acknowledgment:
35.\" "This product includes software developed by the OpenSSL Project
36.\" for use in the OpenSSL Toolkit (http://www.openssl.org/)"
37.\"
38.\" THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY
39.\" EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
40.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
41.\" PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR
42.\" ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
43.\" SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
44.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
45.\" LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
46.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
47.\" STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
48.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
49.\" OF THE POSSIBILITY OF SUCH DAMAGE.
50.\"
51.Dd $Mdocdate: December 5 2023 $
52.Dt OPENSSL_LOAD_BUILTIN_MODULES 3
53.Os
54.Sh NAME
55.Nm OPENSSL_load_builtin_modules ,
56.Nm ASN1_add_oid_module
57.Nd add standard configuration modules
58.Sh SYNOPSIS
59.In openssl/conf.h
60.Ft void
61.Fn OPENSSL_load_builtin_modules void
62.Ft void
63.Fn ASN1_add_oid_module void
64.Sh DESCRIPTION
65The function
66.Fn OPENSSL_load_builtin_modules
67adds all the standard OpenSSL configuration modules to the internal
68list.
69They can then be used by the OpenSSL configuration code.
70.Pp
71.Fn ASN1_add_oid_module
72adds just the ASN.1 OBJECT module.
73.Pp
74If the simple configuration function
75.Xr OPENSSL_config 3
76is called then
77.Fn OPENSSL_load_builtin_modules
78is called automatically.
79.Pp
80Applications which use configuration functions like
81.Xr CONF_modules_load_file 3
82directly need to call
83.Fn OPENSSL_load_builtin_modules
84themselves
85.Em before
86any other configuration code.
87.Pp
88Applications should call
89.Xr OPENSSL_config 3
90or
91.Fn OPENSSL_load_builtin_modules
92to load all configuration modules instead of adding modules selectively:
93otherwise functionality may be missing from the application when
94new modules are added.
95.Sh SEE ALSO
96.Xr CONF_modules_load_file 3 ,
97.Xr OPENSSL_config 3
98.Sh HISTORY
99These functions first appeared in OpenSSL 0.9.7
100and have been available since
101.Ox 3.2 .
diff --git a/src/lib/libcrypto/man/OpenSSL_add_all_algorithms.3 b/src/lib/libcrypto/man/OpenSSL_add_all_algorithms.3
index ff1c3df6d9..64f71590fe 100644
--- a/src/lib/libcrypto/man/OpenSSL_add_all_algorithms.3
+++ b/src/lib/libcrypto/man/OpenSSL_add_all_algorithms.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: OpenSSL_add_all_algorithms.3,v 1.17 2025/06/08 22:40:30 schwarze Exp $ 1.\" $OpenBSD: OpenSSL_add_all_algorithms.3,v 1.18 2025/06/09 12:43:53 schwarze Exp $
2.\" full merge up to: OpenSSL b3696a55 Sep 2 09:35:50 2017 -0400 2.\" full merge up to: OpenSSL b3696a55 Sep 2 09:35:50 2017 -0400
3.\" 3.\"
4.\" This file was written by Dr. Stephen Henson <steve@openssl.org>. 4.\" This file was written by Dr. Stephen Henson <steve@openssl.org>.
@@ -48,7 +48,7 @@
48.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 48.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
49.\" OF THE POSSIBILITY OF SUCH DAMAGE. 49.\" OF THE POSSIBILITY OF SUCH DAMAGE.
50.\" 50.\"
51.Dd $Mdocdate: June 8 2025 $ 51.Dd $Mdocdate: June 9 2025 $
52.Dt OPENSSL_ADD_ALL_ALGORITHMS 3 52.Dt OPENSSL_ADD_ALL_ALGORITHMS 3
53.Os 53.Os
54.Sh NAME 54.Sh NAME
@@ -80,17 +80,21 @@
80These functions are deprecated. 80These functions are deprecated.
81It is never useful for any application program 81It is never useful for any application program
82to call any of them explicitly. 82to call any of them explicitly.
83The library automatically calls them internally whenever needed.
84.Pp 83.Pp
85OpenSSL keeps an internal table of digest algorithms and ciphers. 84The library contains internal tables of digest algorithms and ciphers.
86It uses this table to look up ciphers via functions such as 85It uses these tables to look up digests and ciphers via
87.Xr EVP_get_cipherbyname 3 . 86.Xr EVP_get_digestbyname 3
87and
88.Xr EVP_get_cipherbyname 3 ,
89respectively.
90In LibreSSL, these tables are static constants and do not require
91initialization.
88.Pp 92.Pp
89.Fn OpenSSL_add_all_algorithms 93.Fn OpenSSL_add_all_algorithms
90adds all algorithms to the table (digests and ciphers). 94adds all algorithms to the table (digests and ciphers).
91If an application is compiled with the preprocessor symbol 95If an application is compiled with the preprocessor symbol
92.Dv OPENSSL_LOAD_CONF 96.Dv OPENSSL_LOAD_CONF
93#define'd, it also calls 97defined, it also calls
94.Xr OPENSSL_config 3 98.Xr OPENSSL_config 3
95with a 99with a
96.Dv NULL 100.Dv NULL
@@ -103,17 +107,9 @@ adds all digest algorithms to the table.
103adds all encryption algorithms to the table including password based 107adds all encryption algorithms to the table including password based
104encryption algorithms. 108encryption algorithms.
105.Pp 109.Pp
106If any of the above functions is called more than once,
107only the first call has an effect.
108.Pp
109.Fn EVP_cleanup 110.Fn EVP_cleanup
110removes all ciphers and digests from the table and also calls 111has no effect; it used to remove various kinds of application-supplied
111.Xr OBJ_NAME_cleanup 3 112data that is no longer supported in the first place.
112with an argument of \-1 ,
113thus resetting the global associative array of names
114and all signature algorithm definitions to their default states,
115removing all application-defined types, key-value pairs, and aliases,
116including any that are unrelated to the EVP library.
117.Pp 113.Pp
118.Fn SSLeay_add_all_algorithms 114.Fn SSLeay_add_all_algorithms
119is a deprecated alias for 115is a deprecated alias for
@@ -127,8 +123,6 @@ are implemented as macros.
127.Xr evp 3 , 123.Xr evp 3 ,
128.Xr EVP_DigestInit 3 , 124.Xr EVP_DigestInit 3 ,
129.Xr EVP_EncryptInit 3 , 125.Xr EVP_EncryptInit 3 ,
130.Xr OBJ_cleanup 3 ,
131.Xr OBJ_NAME_add 3 ,
132.Xr OPENSSL_config 3 126.Xr OPENSSL_config 3
133.Sh HISTORY 127.Sh HISTORY
134.Fn EVP_cleanup , 128.Fn EVP_cleanup ,
@@ -149,5 +143,3 @@ first appeared in OpenSSL 0.9.5 and have been available since
149.Sh BUGS 143.Sh BUGS
150Although the functions do not return error codes, it is possible for them 144Although the functions do not return error codes, it is possible for them
151to fail. 145to fail.
152This will only happen as a result of a memory allocation failure so this
153is not too much of a problem in practice.