This is an automated email from the ASF dual-hosted git repository.
markt-asf pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/main by this push:
new f1594cf7f8 Fix possible TLS connections failures
f1594cf7f8 is described below
commit f1594cf7f8beaa3791a7acf832157ea36067950c
Author: Mark Thomas <[email protected]>
AuthorDate: Thu Sep 17 23:22:53 2026 +0100
Fix possible TLS connections failures
Caused by one of the flags Tomcat uses to track TLS handshake progress
not being correctly reset.
---
java/org/apache/tomcat/util/net/SecureNioChannel.java | 3 +++
webapps/docs/changelog.xml | 4 ++++
2 files changed, 7 insertions(+)
diff --git a/java/org/apache/tomcat/util/net/SecureNioChannel.java
b/java/org/apache/tomcat/util/net/SecureNioChannel.java
index 8006e363dd..4fe0ac58a7 100644
--- a/java/org/apache/tomcat/util/net/SecureNioChannel.java
+++ b/java/org/apache/tomcat/util/net/SecureNioChannel.java
@@ -112,6 +112,7 @@ public class SecureNioChannel extends NioChannel {
if (channel != null) {
sniComplete = false;
handshakeComplete = false;
+ needHandshakeWrap = false;
closed = false;
closing = false;
netInBuffer.clear();
@@ -909,6 +910,8 @@ public class SecureNioChannel extends NioChannel {
netOutBuffer.clear();
SSLEngineResult result = sslEngine.wrap(srcs, offset, length,
netOutBuffer);
+ // Call to wrap() will have included any required handshake data
+ needHandshakeWrap = false;
// The number of bytes written
int written = result.bytesConsumed();
netOutBuffer.flip();
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index 34c4de4138..e680dfa14e 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -386,6 +386,10 @@
<fix>
Correct a narrow race condition when processing HTTP/2 headers. (markt)
</fix>
+ <fix>
+ Fix possible TLS connections failures caused by one of the flags Tomcat
+ uses to track TLS handshake progress not being correctly reset. (markt)
+ </fix>
</changelog>
</subsection>
<subsection name="Jasper">
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]