]> git.ipfire.org Git - thirdparty/postfix.git/commitdiff
postfix-3.4-20180618
authorWietse Venema <wietse@porcupine.org>
Mon, 18 Jun 2018 05:00:00 +0000 (00:00 -0500)
committerViktor Dukhovni <postfix-users@dukhovni.org>
Tue, 19 Jun 2018 16:24:02 +0000 (12:24 -0400)
postfix/HISTORY
postfix/RELEASE_NOTES
postfix/src/global/mail_version.h
postfix/src/tlsproxy/tlsproxy.c

index 1ef6ecf5b1202b33b92d96d9249198271964d08e..512e1f3560feadac23800a1c8b79090589079af3 100644 (file)
@@ -23535,3 +23535,13 @@ Apologies for any names omitted.
 
        Release: first production snapshot with multiple outbound
        deliveries per TLS-encrypted connection.
+
+20180618
+
+       Quick tlsproxy workaround: after the remote TLS peer shuts
+       down TLS, allow unsent inbound plaintext to trickle out
+       before tearing down the proxied connection.  This addresses
+       a sporadic "lost connection after end-of-data" error in the
+       Postfix SMTP client, and addresses a sporadic "lost connection
+       after sending QUIT" error with "posttls-finger -X". File:
+       tlsproxy/tlsproxy.c.
index 591c9ab4a40ba0f89188cb31b2435385a39f0922..daf6a00f76a9331327a44b20a3869de5df016c22 100644 (file)
@@ -46,7 +46,7 @@ Postfix 2.8, to support STARTTLS in postscreen(8).
 Under high-traffic conditions, the Postfix SMTP client will use the
 scache(8) connection cache to store and retrieve open connections.
 This part already existed for plaintext SMTP, and it works in the
-same way for TLS-encryped connections.
+same way for TLS-encrypted connections.
 
 The following illustrates how TLS connections are reused:
 
index 762261a23bacef82d4f28767c9a7824ffc76b334..74fa21d88b8dd6c7d95749193b282619abe0a61b 100644 (file)
@@ -20,7 +20,7 @@
   * Patches change both the patchlevel and the release date. Snapshots have no
   * patchlevel; they change the release date only.
   */
-#define MAIL_RELEASE_DATE      "20180617"
+#define MAIL_RELEASE_DATE      "20180618"
 #define MAIL_VERSION_NUMBER    "3.4"
 
 #ifdef SNAPSHOT
index 241e83b2ae91684648d9a2f0f1b4d47b853854c2..5858ad298a0a687d6e51f1f6705eea4c13841a60 100644 (file)
@@ -474,6 +474,12 @@ static int tlsp_eval_tls_error(TLSP_STATE *state, int err)
        tls_print_errors();
        /* FALLTHROUGH */
     default:
+
+       /*
+        * Allow buffered-up plaintext output to trickle out.
+        */
+       if (state->plaintext_buf && NBBIO_WRITE_PEND(state->plaintext_buf))
+           return (TLSP_STAT_OK);
        tlsp_state_free(state);
        return (TLSP_STAT_ERR);
     }
@@ -1013,7 +1019,7 @@ static void tlsp_get_request_event(int event, void *context)
             "(bogus_direction)", state->remote_endpt);
     state->req_flags = req_flags;
     /* state->is_server_role is set below. */
-    state->handshake_timeout = handshake_timeout + 10; /* XXX */
+    state->handshake_timeout = handshake_timeout;
     state->session_timeout = session_timeout + 10;     /* XXX */
 
     /*