summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/conf/README
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/libcrypto/conf/README')
-rw-r--r--src/lib/libcrypto/conf/README47
1 files changed, 21 insertions, 26 deletions
diff --git a/src/lib/libcrypto/conf/README b/src/lib/libcrypto/conf/README
index ca58d0240f..96e53b34ed 100644
--- a/src/lib/libcrypto/conf/README
+++ b/src/lib/libcrypto/conf/README
@@ -1,8 +1,3 @@
1WARNING WARNING WARNING!!!
2
3This stuff is experimental, may change radically or be deleted altogether
4before OpenSSL 0.9.7 release. You have been warned!
5
6Configuration modules. These are a set of modules which can perform 1Configuration modules. These are a set of modules which can perform
7various configuration functions. 2various configuration functions.
8 3
@@ -13,7 +8,7 @@ The routines read a configuration file set up like this:
13 8
14----- 9-----
15#default section 10#default section
16openssl_init=init_section 11openssl_conf=init_section
17 12
18[init_section] 13[init_section]
19 14
@@ -30,29 +25,27 @@ path=/some/path/to/some/dso.so
30other_stuff=other_value 25other_stuff=other_value
31---- 26----
32 27
33When this file is loaded a configuration module with the specified 28When this file is loaded a configuration module with the specified string
34string (module* in the above example) is looked up and its init 29(module* in the above example) is looked up and its init function called as:
35function called as:
36 30
37int conf_init_func(CONF_IMODULE *md, CONF *cnf); 31int conf_init_func(CONF_IMODULE *md, CONF *cnf);
38 32
39The function can then take whatever action is appropriate, for example 33The function can then take whatever action is appropriate, for example further
40further lookups based on the value. Multiple instances of the same 34lookups based on the value. Multiple instances of the same config module can be
41config module can be loaded. 35loaded.
42 36
43When the application closes down the modules are cleaned up by calling 37When the application closes down the modules are cleaned up by calling an
44an optional finish function: 38optional finish function:
45 39
46void conf_finish_func(CONF_IMODULE *md); 40void conf_finish_func(CONF_IMODULE *md);
47 41
48The finish functions are called in reverse order: that is the last module 42The finish functions are called in reverse order: that is the last module
49loaded is the first one cleaned up. 43loaded is the first one cleaned up.
50 44
51If no module exists with a given name then an attempt is made to load 45If no module exists with a given name then an attempt is made to load a DSO
52a DSO with the supplied name. This might mean that "module3" attempts 46with the supplied name. This might mean that "module3" attempts to load a DSO
53to load a DSO called libmodule3.so or module3.dll for example. An explicit 47called libmodule3.so or module3.dll for example. An explicit DSO name can be
54DSO name can be given by including a separate section as in the module4 example 48given by including a separate section as in the module4 example above.
55above.
56 49
57The DSO is expected to at least contain an initialization function: 50The DSO is expected to at least contain an initialization function:
58 51
@@ -64,15 +57,17 @@ void OPENSSL_finish(CONF_IMODULE *md);
64 57
65Static modules can also be added using, 58Static modules can also be added using,
66 59
67int CONF_module_add(char *name, dso_mod_init_func *ifunc, dso_mod_finish_func *ffunc); 60int CONF_module_add(char *name, dso_mod_init_func *ifunc, dso_mod_finish_func
61*ffunc);
68 62
69where "name" is the name in the configuration file this function corresponds to. 63where "name" is the name in the configuration file this function corresponds
64to.
70 65
71A set of builtin modules (currently only an ASN1 non functional test module) can be 66A set of builtin modules (currently only an ASN1 non functional test module)
72added by calling OPENSSL_load_builtin_modules(). 67can be added by calling OPENSSL_load_builtin_modules().
73 68
74The function OPENSSL_config() is intended as a simple configuration function that 69The function OPENSSL_config() is intended as a simple configuration function
75any application can call to perform various default configuration tasks. It uses the 70that any application can call to perform various default configuration tasks.
76file openssl.cnf in the usual locations. 71It uses the file openssl.cnf in the usual locations.
77 72
78 73