[exim-cvs] Log warnings on presence of deperecated options

Αρχική Σελίδα
Delete this message
Reply to this message
Συντάκτης: Exim Git Commits Mailing List
Ημερομηνία:  
Προς: exim-cvs
Αντικείμενο: [exim-cvs] Log warnings on presence of deperecated options
Gitweb: http://git.exim.org/exim.git/commitdiff/2d571266c336367744f6b81b59483227557c3f46
Commit:     2d571266c336367744f6b81b59483227557c3f46
Parent:     91f40ccd9734db907dd7de25147995c50e564c77
Author:     Jeremy Harris <jgh146exb@???>
AuthorDate: Thu May 29 21:57:04 2014 +0100
Committer:  Jeremy Harris <jgh146exb@???>
CommitDate: Thu May 29 22:08:41 2014 +0100


    Log warnings on presence of deperecated options
---
 src/src/readconf.c        |    6 ++++++
 src/src/transports/smtp.c |    9 ++++++++-
 2 files changed, 14 insertions(+), 1 deletions(-)


diff --git a/src/src/readconf.c b/src/src/readconf.c
index fb14763..4db0cbb 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 db424fa..88f796e 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");
 }