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

rmaucher pushed a commit to branch 11.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/11.0.x by this push:
     new dc6006a181 Add clean IAE for missing host name
dc6006a181 is described below

commit dc6006a1813054bffb306df13d3d8122d597b39e
Author: remm <[email protected]>
AuthorDate: Wed May 20 11:51:44 2026 +0200

    Add clean IAE for missing host name
---
 java/org/apache/tomcat/util/net/AbstractEndpoint.java | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/java/org/apache/tomcat/util/net/AbstractEndpoint.java 
b/java/org/apache/tomcat/util/net/AbstractEndpoint.java
index 7f6b412409..85f1c9e234 100644
--- a/java/org/apache/tomcat/util/net/AbstractEndpoint.java
+++ b/java/org/apache/tomcat/util/net/AbstractEndpoint.java
@@ -516,6 +516,9 @@ public abstract class AbstractEndpoint<S, U> {
      * @param hostName The SSL host for which the configuration should be 
reloaded. This must match a current SSL host
      */
     public void reloadSslHostConfig(String hostName) {
+        if (hostName == null) {
+            throw new 
IllegalArgumentException(sm.getString("endpoint.unknownSslHostName", ""));
+        }
         // Host names are case-insensitive but stored/processed in lower case
         // internally because they are used as keys in a ConcurrentMap where
         // keys are compared in a case-sensitive manner.


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to