libcoap 4.3.5-develop-7cf7465
coap-tls-engine-conf(5)
coap-tls-engine-conf

NAME

coap-tls-engine-conf — CoAP TLS ENGINE configuration file format

DESCRIPTION

The TLS ENGINE configuration file is read in and installed when using the *-q* tls_engine_conf_file option for the coap-client(5) or coap-server(5) executables. This then allows a client or server to use the defined TLS ENGINE to do the appropriate TLS functions.

NOTE: Currently only OpenSSL is supported.

It is also read in, parsed and installed by coap_tls_engine_configure(3).

This configuration file can be a configuration held in memory, the formatting of the memory region is same as that for a file as if the file was mapped into memory. The coap_tls_engine_configure(3) function uses the memory version of the file.

The configuration file comprises of a set of keywords, one per line. Each keyword has a parameter with an optional second parameter.

The format of each line is one of (colon separated)

keyword:parameter_1:parameter_2
keyword:parameter_1

For parameter_2, this can be a zero length string. If the preceding character to parameter_2 is not a colon, then parameter_2 is treated as NULL (as in the second example).

The keywords and parameters are case sensitive. If a line starts with a #, then it is treated as a comment line and so is ignored. Empty lines are also valid and ignored.

The possible keywords are:

engine
parameter_1 containes the ENGINE name (ID). parameter_2 is ignored.
pre-cmd
parameter_1 is the command that are to be issued to the ENGINE logic before the ENGINE is initialized. If the command has a parameter, this is passed passed in from parameter_2. Some commands do not have a parameter_2 which usually is enforced by the ENGINE.
post-cmd
parameter_1 is the command that are to be issued to the ENGINE logic after the ENGINE is initialized. If the command has a parameter, this is passed passed in from parameter_2. Some commands do not have a parameter_2 which usually is enforced by the ENGINE.
enable-methods
parameter_1 is the numeric value of the or’d set of required ENGINE_METHOD_* or ENGINE_METHOD_ALL. parameter_1 can be an ascii representation of a number or formated as 0xXXXX. parameter_2 is ignored.

EXAMPLE TLS ENGINE CONFIGURATION FILE

# Define the engine name
engine:pkcs11

# Define which methods are to be enabled
enable-methods:0xffff

# Define any post initialization commands
post-cmd:PIN:1234

FURTHER INFORMATION

See

"RFC7252: The Constrained Application Protocol (CoAP)"

for further information.

BUGS

Please raise an issue on GitHub at https://github.com/obgm/libcoap/issues to report any bugs.

Please raise a Pull Request at https://github.com/obgm/libcoap/pulls for any fixes.

AUTHORS

The libcoap project <libcoap-developers@lists.sourceforge.net>

coap-tls-engine-conf(5)