This is an automated email from the ASF dual-hosted git repository.

moonchen pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/trafficserver.git


The following commit(s) were added to refs/heads/master by this push:
     new c64d786be6 ssl: remove the dead SSL_HOOK_OP_TERMINATE op (#13407)
c64d786be6 is described below

commit c64d786be619a2e6e8f3f0d5e01d2ac68ba21a81
Author: Mo Chen <[email protected]>
AuthorDate: Mon Jul 20 11:27:20 2026 -0500

    ssl: remove the dead SSL_HOOK_OP_TERMINATE op (#13407)
    
    No code has ever assigned hookOpRequested this value: the introducing
    commit (TS-3006, 2014) only wrote it to an example plugin's own struct,
    and the public TSSslVConnOp API that could have set it was removed in
    2016 (TS-4658). A hook rejects a handshake via
    TSVConnReenableEx(TS_EVENT_ERROR) instead, so drop the enumerator and
    its unreachable arm in sslServerHandShakeEvent().
---
 src/iocore/net/P_SSLNetVConnection.h | 5 ++---
 src/iocore/net/SSLNetVConnection.cc  | 3 ---
 2 files changed, 2 insertions(+), 6 deletions(-)

diff --git a/src/iocore/net/P_SSLNetVConnection.h 
b/src/iocore/net/P_SSLNetVConnection.h
index 3ff284ff8c..ee1a04d9e2 100644
--- a/src/iocore/net/P_SSLNetVConnection.h
+++ b/src/iocore/net/P_SSLNetVConnection.h
@@ -81,9 +81,8 @@ constexpr int      SSL_DEF_TLS_RECORD_MSEC_THRESHOLD = 1000;
 struct SSLCertLookup;
 
 enum class SslVConnOp {
-  SSL_HOOK_OP_DEFAULT,  ///< Null / initialization value. Do normal processing.
-  SSL_HOOK_OP_TUNNEL,   ///< Switch to blind tunnel
-  SSL_HOOK_OP_TERMINATE ///< Termination connection / transaction.
+  SSL_HOOK_OP_DEFAULT, ///< Null / initialization value. Do normal processing.
+  SSL_HOOK_OP_TUNNEL   ///< Switch to blind tunnel
 };
 
 enum class SSLHandshakeStatus { SSL_HANDSHAKE_ONGOING, SSL_HANDSHAKE_DONE, 
SSL_HANDSHAKE_ERROR };
diff --git a/src/iocore/net/SSLNetVConnection.cc 
b/src/iocore/net/SSLNetVConnection.cc
index 2a2ac30836..3280641215 100644
--- a/src/iocore/net/SSLNetVConnection.cc
+++ b/src/iocore/net/SSLNetVConnection.cc
@@ -1309,9 +1309,6 @@ SSLNetVConnection::sslServerHandShakeEvent(int &err)
     // we get out of this callback, and then will shuffle
     // over the buffered handshake packets to the O.S.
     return EVENT_DONE;
-  } else if (SslVConnOp::SSL_HOOK_OP_TERMINATE == hookOpRequested) {
-    sslHandshakeStatus = SSLHandshakeStatus::SSL_HANDSHAKE_DONE;
-    return EVENT_DONE;
   }
 
   Dbg(dbg_ctl_ssl, "Go on with the handshake state=%s",

Reply via email to