Commit Graph

23 Commits (1924afe49ed2375bf3c78c3d4ac6f60f7d7be2ea)

Author SHA1 Message Date
Roger A. Light 1924afe49e Add explicit support for TLS v1.3 and drop TLS v1.0. 7 years ago
Roger A. Light 5aabc171b0 Merge branch 'mqtt5' into develop 7 years ago
Roger A. Light e862a047a8 Rework TLS engine support. 7 years ago
Nicolás Pernas Maradei 20894fcbce Add engine private key password support
Some OpenSSL engines (selectable via tls_engine option) may require a
password to make use of private keys created with them in the first place.

The TPM engine for example, will require a password to access the underlying
TPM's Storage Root Key (SRK), which is the root key of a hierarchy of keys
associated with a TPM; it is generated within a TPM and is a non-migratable
key. Each owned TPM contains a SRK, generated by the TPM at the request
of the Owner. [1]

By default, the engine will prompt the user to introduce the SRK password
before any private keys created with the engine can be used. This could
be inconvenient when running on an unattended system.

Here's where the new tls_engine_kpass_sha option comes in handy. The user
can specify a SHA1 hash of its engine private key password via command
line or config file and it will be passed on to the engine directly.

This commit adds support for both clients (libmosquitto) and broker.

[1] https://goo.gl/qQoXBY

Signed-off-by: Nicolás Pernas Maradei <nicopernas@gmail.com>
7 years ago
Nicolás Pernas Maradei f88cc06435 Add TLS engine and keyform support to libmosquitto
- Clients can now offload crypto tasks to an external crypto device through
  the OpenSSL ENGINE API.
- The keyfiles can now be treated as PEM or ENGINE keys.
- Two new functions were added to libmosquitto to set up the previously
  mentioned features.
- Both mosquitto_sub and mosquitto_pub include support to turn on the mentioned
  features through command line options.

Signed-off-by: Nicolás Pernas Maradei <nicopernas@gmail.com>
7 years ago
Roger Light 84660e1cbe Send maximum limits for QoS>0.
This needs more work on the broker front to simplify the design.
7 years ago
Roger Light 67c1d4453e Receive maximum support for clients. 7 years ago
Roger Light 0546e7bebc Add mosquitto_int_option and mosquitto_void_option
This deprecates mosquitto_opts_set().
7 years ago
Roger A. Light fcf4cd0b27 Merge branch 'master' into mqtt5 7 years ago
Roger A. Light a00dd29af8 Fix building where TLS-PSK is not available.
Closes #68.
7 years ago
Roger A. Light 5d02f58151 Fix reconnect delay backoff behaviour.
Closes #1027. Thanks to Harm Verhagen.

Bug: https://github.com/eclipse/mosquitto/issues/1027
7 years ago
Roger A. Light 0123ff1efe Rename *_with_properties() -> *_v5(). 7 years ago
Roger A. Light f9e0fa246a Validate properties coming into client library. 7 years ago
Roger A. Light 383608613a Client+lib will property support. 7 years ago
Roger A. Light 561513fdd4 Very simple v5 CONNECT support - no properties. 7 years ago
Roger A. Light 8410a19335 Add fallback case for libressl. 8 years ago
Roger A. Light 6c7ecd7e97 Fix compiling without TLS. 8 years ago
Roger A. Light b2bb48ac2b Reference counting for openssl 1.0.2. 8 years ago
Roger A. Light 574fb36ede More utf-8 validation. 8 years ago
Roger A. Light 2d9fab123e Use SSL_CTX_up_ref() with MOSQ_OPT_SSL_CTX*.
This limits the use of those options to openssl 1.1.0 and greater.
8 years ago
Roger A. Light 24d68b5af8 Remove support for openssl 1.0.0 and 1.0.1.
These are no longer supported by openssl.
8 years ago
Roger A. Light 8470ca89b9 Add MOSQ_OPT_SSL_CTX and MOSQ_OPT_SSL_CTX_WITH_DEFAULTS options.
Closes #567 and #715.
8 years ago
Roger A. Light 28dd14fcea Separate out functions from mosquitto.c to aid discoverability. 8 years ago