diff options
author | defanor <defanor@uberspace.net> | 2021-09-19 22:05:38 +0300 |
---|---|---|
committer | defanor <defanor@uberspace.net> | 2021-09-19 22:05:38 +0300 |
commit | c84f9e76d8e93c37b974c0fc64a6afdf432595cc (patch) | |
tree | 0829e751c2d19d7752a8c785ac8c021bba1852ea /src/rexmpp.h | |
parent | 26745d3a4e21ecf46492445b9c0251d80890bf62 (diff) |
Introduce OpenSSL and no-TLS options, in addition to GnuTLS
Also an option to require TLS is added.
There's no DANE TLSA checks with OpenSSL yet, TLS session resumptions
and ALPN aren't used with it; just basic connections with certificate
verification are added. And now SASL EXTERNAL authentication isn't
quite usable.
Diffstat (limited to 'src/rexmpp.h')
-rw-r--r-- | src/rexmpp.h | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/src/rexmpp.h b/src/rexmpp.h index 93740d8..b47703f 100644 --- a/src/rexmpp.h +++ b/src/rexmpp.h @@ -11,17 +11,18 @@ #include <stdint.h> #include <unbound.h> -#include <gnutls/gnutls.h> #include <gsasl.h> #include <libxml/tree.h> #include <gpgme.h> + +typedef struct rexmpp rexmpp_t; + #include "rexmpp_tcp.h" #include "rexmpp_socks.h" #include "rexmpp_dns.h" +#include "rexmpp_tls.h" #include "rexmpp_jid.h" -typedef struct rexmpp rexmpp_t; - /** @brief An info/query callback function type. @param[in,out] s A ::rexmpp structure. @@ -253,6 +254,7 @@ struct rexmpp int nick_notifications; /* XEP-0172 */ int retrieve_openpgp_keys; /* XEP-0373 */ int autojoin_bookmarked_mucs; /* XEP-0402 */ + int require_tls; /* Resource limits. */ uint32_t stanza_queue_size; @@ -338,10 +340,7 @@ struct rexmpp xmlNodePtr input_queue_last; /* TLS structures. */ - void *tls_session_data; - size_t tls_session_data_size; - gnutls_session_t gnutls_session; - gnutls_certificate_credentials_t gnutls_cred; + rexmpp_tls_t tls; /* SASL structures. */ Gsasl *sasl_ctx; |