From 2d571266c336367744f6b81b59483227557c3f46 Mon Sep 17 00:00:00 2001 From: Jeremy Harris Date: Thu, 29 May 2014 21:57:04 +0100 Subject: Log warnings on presence of deperecated options --- src/src/readconf.c | 6 ++++++ src/src/transports/smtp.c | 9 ++++++++- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/src/src/readconf.c b/src/src/readconf.c index fb1476365..4db0cbbe5 100644 --- a/src/src/readconf.c +++ b/src/src/readconf.c @@ -249,6 +249,7 @@ static optionlist optionlist_config[] = { { "gnutls_allow_auto_pkcs11", opt_bool, &gnutls_allow_auto_pkcs11 }, { "gnutls_compat_mode", opt_bool, &gnutls_compat_mode }, /* These three gnutls_require_* options stopped working in Exim 4.80 */ + /* From 4.83 we log a warning; a future relase will remove them */ { "gnutls_require_kx", opt_stringptr, &gnutls_require_kx }, { "gnutls_require_mac", opt_stringptr, &gnutls_require_mac }, { "gnutls_require_protocols", opt_stringptr, &gnutls_require_proto }, @@ -3374,6 +3375,11 @@ if (openssl_options != NULL) # endif } #endif + +if (gnutls_require_kx || gnutls_require_mac || gnutls_require_proto) + log_write(0, LOG_MAIN, "WARNING: main options" + " gnutls_require_kx, gnutls_require_mac and gnutls_require_protocols" + " are obsolete\n"); } diff --git a/src/src/transports/smtp.c b/src/src/transports/smtp.c index db424fa61..88f796e33 100644 --- a/src/src/transports/smtp.c +++ b/src/src/transports/smtp.c @@ -69,7 +69,7 @@ optionlist smtp_transport_options[] = { (void *)offsetof(smtp_transport_options_block, gethostbyname) }, #ifdef SUPPORT_TLS /* These are no longer honoured, as of Exim 4.80; for now, we silently - ignore; a later release will warn, and a later-still release will remove + ignore; 4.83 will warn, and a later-still release will remove these options, so that using them becomes an error. */ { "gnutls_require_kx", opt_stringptr, (void *)offsetof(smtp_transport_options_block, gnutls_require_kx) }, @@ -400,6 +400,13 @@ if (ob->hosts_override && ob->hosts != NULL) tblock->overrides_hosts = TRUE; for them, but do not do any lookups at this time. */ host_build_hostlist(&(ob->fallback_hostlist), ob->fallback_hosts, FALSE); + +if ( ob->gnutls_require_kx + || ob->gnutls_require_mac + || ob->gnutls_require_proto) + log_write(0, LOG_MAIN, "WARNING: smtp transport options" + " gnutls_require_kx, gnutls_require_mac and gnutls_require_protocols" + " are obsolete\n"); } -- cgit v1.2.3