From: Pierre Habouzit Date: Sun, 13 Jan 2008 21:30:58 +0000 (+0100) Subject: drop mod_ssl.starttls setting. X-Git-Url: http://git.madism.org/?a=commitdiff_plain;h=98f62b5fcbd680fd5214ee85e1635b84322cbdd1;p=apps%2Fmadmutt.git drop mod_ssl.starttls setting. Of course we want to use starttls if available doh Signed-off-by: Pierre Habouzit --- diff --git a/imap/imap.c b/imap/imap.c index 1bd9c95..83bb6da 100644 --- a/imap/imap.c +++ b/imap/imap.c @@ -383,17 +383,15 @@ int imap_open_connection (IMAP_DATA * idata) if (mod_ssl.force_tls) rc = M_YES; - else if (mod_ssl.starttls) { + else { if ((rc = imap_exec (idata, "STARTTLS", IMAP_CMD_FAIL_OK)) == -1) goto bail; if (rc != -2) { - if (mutt_ssl_starttls (idata->conn)) - { + if (mutt_ssl_starttls (idata->conn)) { mutt_error (_("Could not negotiate TLS connection")); mutt_sleep (1); goto err_close_conn; - } - else { + } else { /* RFC 2595 demands we recheck CAPABILITY after TLS completes. */ if (imap_exec (idata, "CAPABILITY", 0)) goto bail; diff --git a/lib-lua/lua-token.gperf b/lib-lua/lua-token.gperf index f637176..a0f727f 100644 --- a/lib-lua/lua-token.gperf +++ b/lib-lua/lua-token.gperf @@ -159,7 +159,6 @@ exit 0 ## signature ## smime_is_default ## spam_separator -## starttls ## sysconfdir ## threshold_delete ## threshold_flag diff --git a/lib-mx/pop.c b/lib-mx/pop.c index 189cb5d..ee18bc3 100644 --- a/lib-mx/pop.c +++ b/lib-mx/pop.c @@ -64,7 +64,6 @@ typedef struct { unsigned status : 2; unsigned capabilities : 1; - unsigned use_stls : 2; cmd_status cmd_capa : 2; /* optional command CAPA */ cmd_status cmd_stls : 2; /* optional command STLS */ cmd_status cmd_uidl : 2; /* optional command UIDL */ @@ -661,27 +660,18 @@ static pop_query_status pop_open_connection (pop_data_t * pop_data) /* Attempt STLS if available and desired. */ if (!pop_data->conn->ssf && (pop_data->cmd_stls || mod_ssl.force_tls)) { - if (mod_ssl.force_tls) - pop_data->use_stls = 2; - if (pop_data->use_stls == 0) { - pop_data->use_stls = 1; - if (mod_ssl.starttls) - pop_data->use_stls = 2; + ret = pop_query(pop_data, buf, sizeof(buf), "STLS"); + if (ret == PQ_NOT_CONNECTED) + goto err_conn; + if (ret != PQ_OK) { + mutt_error ("%s", pop_data->err_msg); + mutt_sleep (2); } - if (pop_data->use_stls == 2) { - ret = pop_query(pop_data, buf, sizeof(buf), "STLS"); - if (ret == PQ_NOT_CONNECTED) - goto err_conn; - if (ret != PQ_OK) { - mutt_error ("%s", pop_data->err_msg); - mutt_sleep (2); - } - else if (mutt_ssl_starttls (pop_data->conn)) - { - mutt_error (_("Could not negotiate TLS connection")); - mutt_sleep (2); - return PQ_ERR; - } + else if (mutt_ssl_starttls (pop_data->conn)) + { + mutt_error (_("Could not negotiate TLS connection")); + mutt_sleep (2); + return PQ_ERR; } } diff --git a/lib-sys/mutt_ssl.cpkg b/lib-sys/mutt_ssl.cpkg index 5623938..b1816c4 100644 --- a/lib-sys/mutt_ssl.cpkg +++ b/lib-sys/mutt_ssl.cpkg @@ -31,13 +31,6 @@ ** since it would otherwise have to abort the connection anyway. This ** option supersedes ``$$ssl_starttls''. */ - bool starttls = 1; - /* - ** .pp - ** If \fIset\fP (the default), Madmutt will attempt to use STARTTLS on servers - ** advertising the capability. When \fIunset\fP, Madmutt will not attempt to - ** use STARTTLS regardless of the server's capabilities. - */ bool use_sslv3 = 1; /* ** .pp