You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2020/01/21 16:23:08 UTC

[tomcat] branch 8.5.x updated: Clean-up. Align 8.5.x with master/9.0.x.

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

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


The following commit(s) were added to refs/heads/8.5.x by this push:
     new 43c889e  Clean-up. Align 8.5.x with master/9.0.x.
43c889e is described below

commit 43c889edbbd9b09d7df0678d7f908db7534fbaaa
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Tue Jan 21 16:22:28 2020 +0000

    Clean-up. Align 8.5.x with master/9.0.x.
---
 .../org/apache/coyote/ajp/AbstractAjpProtocol.java | 38 +++++----
 .../coyote/http11/AbstractHttp11Protocol.java      | 97 +++++++++++++++++-----
 .../apache/coyote/http11/Http11InputBuffer.java    |  7 +-
 java/org/apache/coyote/http11/Http11Processor.java |  1 -
 java/org/apache/tomcat/util/http/MimeHeaders.java  |  5 +-
 .../apache/tomcat/util/http/parser/HttpParser.java | 32 +++----
 .../util/http/parser/LocalStrings.properties       |  8 +-
 .../util/http/parser/LocalStrings_fr.properties    |  7 ++
 .../util/http/parser/LocalStrings_ja.properties    |  7 ++
 .../util/http/parser/LocalStrings_ko.properties    |  7 ++
 .../util/http/parser/LocalStrings_zh_CN.properties |  7 ++
 webapps/docs/config/ajp.xml                        |  4 +-
 webapps/docs/config/http.xml                       |  4 +-
 13 files changed, 159 insertions(+), 65 deletions(-)

diff --git a/java/org/apache/coyote/ajp/AbstractAjpProtocol.java b/java/org/apache/coyote/ajp/AbstractAjpProtocol.java
index 46bf9d7..872dbe6 100644
--- a/java/org/apache/coyote/ajp/AbstractAjpProtocol.java
+++ b/java/org/apache/coyote/ajp/AbstractAjpProtocol.java
@@ -93,50 +93,58 @@ public abstract class AbstractAjpProtocol<S> extends AbstractProtocol<S> {
     // ------------------------------------------------- AJP specific properties
     // ------------------------------------------ managed in the ProtocolHandler
 
-    /**
-     * Send AJP flush packet when flushing.
-     * An flush packet is a zero byte AJP13 SEND_BODY_CHUNK
-     * packet. mod_jk and mod_proxy_ajp interprete this as
-     * a request to flush data to the client.
-     * AJP always does flush at the and of the response, so if
-     * it is not important, that the packets get streamed up to
-     * the client, do not use extra flush packets.
-     * For compatibility and to stay on the safe side, flush
-     * packets are enabled by default.
-     */
     protected boolean ajpFlush = true;
     public boolean getAjpFlush() { return ajpFlush; }
+    /**
+     * Configure whether to aend an AJP flush packet when flushing. A flush
+     * packet is a zero byte AJP13 SEND_BODY_CHUNK packet. mod_jk and
+     * mod_proxy_ajp interpret this as a request to flush data to the client.
+     * AJP always does flush at the and of the response, so if it is not
+     * important, that the packets get streamed up to the client, do not use
+     * extra flush packets. For compatibility and to stay on the safe side,
+     * flush packets are enabled by default.
+     *
+     * @param ajpFlush  The new flush setting
+     */
     public void setAjpFlush(boolean ajpFlush) {
         this.ajpFlush = ajpFlush;
     }
 
 
+    private boolean tomcatAuthentication = true;
     /**
      * Should authentication be done in the native web server layer,
      * or in the Servlet container ?
+     *
+     * @return {@code true} if authentication should be performed by Tomcat,
+     *         otherwise {@code false}
      */
-    private boolean tomcatAuthentication = true;
     public boolean getTomcatAuthentication() { return tomcatAuthentication; }
     public void setTomcatAuthentication(boolean tomcatAuthentication) {
         this.tomcatAuthentication = tomcatAuthentication;
     }
 
 
+    private boolean tomcatAuthorization = false;
     /**
      * Should authentication be done in the native web server layer and
      * authorization in the Servlet container?
+     *
+     * @return {@code true} if authorization should be performed by Tomcat,
+     *         otherwise {@code false}
      */
-    private boolean tomcatAuthorization = false;
     public boolean getTomcatAuthorization() { return tomcatAuthorization; }
     public void setTomcatAuthorization(boolean tomcatAuthorization) {
         this.tomcatAuthorization = tomcatAuthorization;
     }
 
 
+    private String requiredSecret = null;
     /**
-     * Required secret.
+     * Set the required secret that must be included with every request.
+     *
+     * @param requiredSecret The required secret
      */
-    private String requiredSecret = null;
     public void setRequiredSecret(String requiredSecret) {
         this.requiredSecret = requiredSecret;
     }
diff --git a/java/org/apache/coyote/http11/AbstractHttp11Protocol.java b/java/org/apache/coyote/http11/AbstractHttp11Protocol.java
index 599b0eb..5332f9b 100644
--- a/java/org/apache/coyote/http11/AbstractHttp11Protocol.java
+++ b/java/org/apache/coyote/http11/AbstractHttp11Protocol.java
@@ -64,6 +64,9 @@ public abstract class AbstractHttp11Protocol<S> extends AbstractProtocol<S> {
 
     @Override
     public void init() throws Exception {
+        // Upgrade protocols have to be configured first since the endpoint
+        // init (triggered via super.init() below) uses this list to configure
+        // the list of ALPN protocols to advertise
         for (UpgradeProtocol upgradeProtocol : upgradeProtocols) {
             configureUpgradeProtocol(upgradeProtocol);
         }
@@ -166,13 +169,26 @@ public abstract class AbstractHttp11Protocol<S> extends AbstractProtocol<S> {
     }
 
 
+    private int maxSavePostSize = 4 * 1024;
     /**
-     * Maximum size of the post which will be saved when processing certain
-     * requests, such as a POST.
+     * Return the maximum size of the post which will be saved during FORM or
+     * CLIENT-CERT authentication.
+     *
+     * @return The size in bytes
      */
-    private int maxSavePostSize = 4 * 1024;
     public int getMaxSavePostSize() { return maxSavePostSize; }
-    public void setMaxSavePostSize(int valueI) { maxSavePostSize = valueI; }
+    /**
+     * Set the maximum size of a POST which will be buffered during FORM or
+     * CLIENT-CERT authentication. When a POST is received where the security
+     * constraints require a client certificate, the POST body needs to be
+     * buffered while an SSL handshake takes place to obtain the certificate. A
+     * similar buffering is required during FDORM auth.
+     *
+     * @param maxSavePostSize The maximum size POST body to buffer in bytes
+     */
+    public void setMaxSavePostSize(int maxSavePostSize) {
+        this.maxSavePostSize = maxSavePostSize;
+    }
 
 
     /**
@@ -183,41 +199,58 @@ public abstract class AbstractHttp11Protocol<S> extends AbstractProtocol<S> {
     public void setMaxHttpHeaderSize(int valueI) { maxHttpHeaderSize = valueI; }
 
 
+    private int connectionUploadTimeout = 300000;
     /**
-     * Specifies a different (usually  longer) connection timeout during data
-     * upload.
+     * Specifies a different (usually longer) connection timeout during data
+     * upload. Default is 5 minutes as in Apache HTTPD server.
+     *
+     * @return The timeout in milliseconds
      */
-    private int connectionUploadTimeout = 300000;
     public int getConnectionUploadTimeout() { return connectionUploadTimeout; }
-    public void setConnectionUploadTimeout(int i) {
-        connectionUploadTimeout = i;
+    /**
+     * Set the upload timeout.
+     *
+     * @param timeout Upload timeout in milliseconds
+     */
+    public void setConnectionUploadTimeout(int timeout) {
+        connectionUploadTimeout = timeout;
     }
 
 
+    private boolean disableUploadTimeout = true;
     /**
-     * If true, the connectionUploadTimeout will be ignored and the regular
-     * socket timeout will be used for the full duration of the connection.
+     * Get the flag that controls upload time-outs. If true, the
+     * connectionUploadTimeout will be ignored and the regular socket timeout
+     * will be used for the full duration of the connection.
+     *
+     * @return {@code true} if the separate upload timeout is disabled
      */
-    private boolean disableUploadTimeout = true;
     public boolean getDisableUploadTimeout() { return disableUploadTimeout; }
+    /**
+     * Set the flag to control whether a separate connection timeout is used
+     * during upload of a request body.
+     *
+     * @param isDisabled {@code true} if the separate upload timeout should be
+     *                   disabled
+     */
     public void setDisableUploadTimeout(boolean isDisabled) {
         disableUploadTimeout = isDisabled;
     }
 
 
+    public void setCompression(String compression) {
+        compressionConfig.setCompression(compression);
+    }
     public String getCompression() {
         return compressionConfig.getCompression();
     }
-    public void setCompression(String valueS) {
-        compressionConfig.setCompression(valueS);
-    }
 
 
     public String getNoCompressionUserAgents() {
         return compressionConfig.getNoCompressionUserAgents();
     }
-    public void setNoCompressionUserAgents(String valueS) {
-        compressionConfig.setNoCompressionUserAgents(valueS);
+    public void setNoCompressionUserAgents(String noCompressionUserAgents) {
+        compressionConfig.setNoCompressionUserAgents(noCompressionUserAgents);
     }
 
 
@@ -261,8 +294,8 @@ public abstract class AbstractHttp11Protocol<S> extends AbstractProtocol<S> {
     public int getCompressionMinSize() {
         return compressionConfig.getCompressionMinSize();
     }
-    public void setCompressionMinSize(int valueI) {
-        compressionConfig.setCompressionMinSize(valueI);
+    public void setCompressionMinSize(int compressionMinSize) {
+        compressionConfig.setCompressionMinSize(compressionMinSize);
     }
 
 
@@ -292,17 +325,27 @@ public abstract class AbstractHttp11Protocol<S> extends AbstractProtocol<S> {
     }
 
 
-    /**
-     * Server header.
-     */
     private String server;
     public String getServer() { return server; }
-    public void setServer( String server ) {
+    /**
+     * Set the server header name.
+     *
+     * @param server The new value to use for the server header
+     */
+    public void setServer(String server) {
         this.server = server;
     }
 
 
     private boolean serverRemoveAppProvidedValues = false;
+    /**
+     * Should application provider values for the HTTP Server header be removed.
+     * Note that if {@link #server} is set, any application provided value will
+     * be over-ridden.
+     *
+     * @return {@code true} if application provided values should be removed,
+     *         otherwise {@code false}
+     */
     public boolean getServerRemoveAppProvidedValues() { return serverRemoveAppProvidedValues; }
     public void setServerRemoveAppProvidedValues(boolean serverRemoveAppProvidedValues) {
         this.serverRemoveAppProvidedValues = serverRemoveAppProvidedValues;
@@ -410,6 +453,7 @@ public abstract class AbstractHttp11Protocol<S> extends AbstractProtocol<S> {
         return upgradeProtocols.toArray(new UpgradeProtocol[0]);
     }
 
+
     /**
      * The protocols that are available via internal Tomcat support for access
      * via HTTP upgrade.
@@ -487,6 +531,13 @@ public abstract class AbstractHttp11Protocol<S> extends AbstractProtocol<S> {
     public int getMaxKeepAliveRequests() {
         return getEndpoint().getMaxKeepAliveRequests();
     }
+    /**
+     * Set the maximum number of Keep-Alive requests to allow.
+     * This is to safeguard from DoS attacks. Setting to a negative
+     * value disables the limit.
+     *
+     * @param mkar The new maximum number of Keep-Alive requests allowed
+     */
     public void setMaxKeepAliveRequests(int mkar) {
         getEndpoint().setMaxKeepAliveRequests(mkar);
     }
diff --git a/java/org/apache/coyote/http11/Http11InputBuffer.java b/java/org/apache/coyote/http11/Http11InputBuffer.java
index 620f381..a0dba8e 100644
--- a/java/org/apache/coyote/http11/Http11InputBuffer.java
+++ b/java/org/apache/coyote/http11/Http11InputBuffer.java
@@ -20,6 +20,7 @@ import java.io.EOFException;
 import java.io.IOException;
 import java.nio.ByteBuffer;
 import java.nio.charset.StandardCharsets;
+import java.util.Arrays;
 
 import org.apache.coyote.InputBuffer;
 import org.apache.coyote.Request;
@@ -189,10 +190,7 @@ public class Http11InputBuffer implements InputBuffer, ApplicationBufferHandler
             throw new NullPointerException(sm.getString("iib.filter.npe"));
         }
 
-        InputFilter[] newFilterLibrary = new InputFilter[filterLibrary.length + 1];
-        for (int i = 0; i < filterLibrary.length; i++) {
-            newFilterLibrary[i] = filterLibrary[i];
-        }
+        InputFilter[] newFilterLibrary = Arrays.copyOf(filterLibrary, filterLibrary.length + 1);
         newFilterLibrary[filterLibrary.length] = filter;
         filterLibrary = newFilterLibrary;
 
@@ -342,6 +340,7 @@ public class Http11InputBuffer implements InputBuffer, ApplicationBufferHandler
      * @throws IOException If an exception occurs during the underlying socket
      * read operations, or if the given buffer is not big enough to accommodate
      * the whole line.
+     *
      * @return true if data is properly fed; false if no data is available
      * immediately and thread should be freed
      */
diff --git a/java/org/apache/coyote/http11/Http11Processor.java b/java/org/apache/coyote/http11/Http11Processor.java
index 325c3c7..99be5f9 100644
--- a/java/org/apache/coyote/http11/Http11Processor.java
+++ b/java/org/apache/coyote/http11/Http11Processor.java
@@ -777,7 +777,6 @@ public class Http11Processor extends AbstractProcessor {
         }
         MessageBytes protocolMB = request.protocol();
         if (protocolMB.equals(Constants.HTTP_11)) {
-            http11 = true;
             protocolMB.setString(Constants.HTTP_11);
         } else if (protocolMB.equals(Constants.HTTP_10)) {
             http11 = false;
diff --git a/java/org/apache/tomcat/util/http/MimeHeaders.java b/java/org/apache/tomcat/util/http/MimeHeaders.java
index 59504ee..a6aa684 100644
--- a/java/org/apache/tomcat/util/http/MimeHeaders.java
+++ b/java/org/apache/tomcat/util/http/MimeHeaders.java
@@ -286,7 +286,7 @@ public class MimeHeaders {
      * @return the message bytes container for the value
      */
     public MessageBytes addValue( String name ) {
-         MimeHeaderField mh = createHeader();
+        MimeHeaderField mh = createHeader();
         mh.getName().setString(name);
         return mh.getValue();
     }
@@ -300,8 +300,7 @@ public class MimeHeaders {
      * @param len Length
      * @return the message bytes container for the value
      */
-    public MessageBytes addValue(byte b[], int startN, int len)
-    {
+    public MessageBytes addValue(byte b[], int startN, int len) {
         MimeHeaderField mhf=createHeader();
         mhf.getName().setBytes(b, startN, len);
         return mhf.getValue();
diff --git a/java/org/apache/tomcat/util/http/parser/HttpParser.java b/java/org/apache/tomcat/util/http/parser/HttpParser.java
index 90d7e42..b089b03 100644
--- a/java/org/apache/tomcat/util/http/parser/HttpParser.java
+++ b/java/org/apache/tomcat/util/http/parser/HttpParser.java
@@ -919,27 +919,27 @@ public class HttpParser {
 
 
     private enum DomainParseState {
-        NEW(     true, false, false, false, " at the start of"),
-        ALPHA(   true,  true,  true,  true, " after a letter in"),
-        NUMERIC( true,  true,  true,  true, " after a number in"),
-        PERIOD(  true, false, false,  true, " after a period in"),
-        HYPHEN(  true,  true, false, false, " after a hypen in"),
-        COLON(  false, false, false, false, " after a colon in"),
-        END(    false, false, false, false, " at the end of");
+        NEW(     true, false, false, false, "http.invalidCharacterDomain.atStart"),
+        ALPHA(   true,  true,  true,  true, "http.invalidCharacterDomain.afterLetter"),
+        NUMERIC( true,  true,  true,  true, "http.invalidCharacterDomain.afterNumber"),
+        PERIOD(  true, false, false,  true, "http.invalidCharacterDomain.afterPeriod"),
+        HYPHEN(  true,  true, false, false, "http.invalidCharacterDomain.afterHyphen"),
+        COLON(  false, false, false, false, "http.invalidCharacterDomain.afterColon"),
+        END(    false, false, false, false, "http.invalidCharacterDomain.atEnd");
 
         private final boolean mayContinue;
         private final boolean allowsHyphen;
         private final boolean allowsPeriod;
         private final boolean allowsEnd;
-        private final String errorLocation;
+        private final String errorMsg;
 
         private DomainParseState(boolean mayContinue, boolean allowsHyphen, boolean allowsPeriod,
-                boolean allowsEnd, String errorLocation) {
+                boolean allowsEnd, String errorMsg) {
             this.mayContinue = mayContinue;
             this.allowsHyphen = allowsHyphen;
             this.allowsPeriod = allowsPeriod;
             this.allowsEnd = allowsEnd;
-            this.errorLocation = errorLocation;
+            this.errorMsg = errorMsg;
         }
 
         public boolean mayContinue() {
@@ -962,22 +962,22 @@ public class HttpParser {
                 if (allowsPeriod) {
                     return PERIOD;
                 } else {
-                    throw new IllegalArgumentException(sm.getString("http.invalidCharacterDomain",
-                            Character.toString((char) c), errorLocation));
+                    throw new IllegalArgumentException(sm.getString(errorMsg,
+                            Character.toString((char) c)));
                 }
             } else if (c == ':') {
                 if (allowsEnd) {
                     return COLON;
                 } else {
-                    throw new IllegalArgumentException(sm.getString("http.invalidCharacterDomain",
-                            Character.toString((char) c), errorLocation));
+                    throw new IllegalArgumentException(sm.getString(errorMsg,
+                            Character.toString((char) c)));
                 }
             } else if (c == '-') {
                 if (allowsHyphen) {
                     return HYPHEN;
                 } else {
-                    throw new IllegalArgumentException(sm.getString("http.invalidCharacterDomain",
-                            Character.toString((char) c), errorLocation));
+                    throw new IllegalArgumentException(sm.getString(errorMsg,
+                            Character.toString((char) c)));
                 }
             } else {
                 throw new IllegalArgumentException(sm.getString(
diff --git a/java/org/apache/tomcat/util/http/parser/LocalStrings.properties b/java/org/apache/tomcat/util/http/parser/LocalStrings.properties
index 8421e4f..7329ca9 100644
--- a/java/org/apache/tomcat/util/http/parser/LocalStrings.properties
+++ b/java/org/apache/tomcat/util/http/parser/LocalStrings.properties
@@ -26,7 +26,13 @@ http.illegalAfterIpv6=The character [{0}] is not permitted to follow an IPv6 add
 http.illegalCharacterDomain=The character [{0}] is never valid in a domain name.
 http.illegalCharacterIpv4=The character [{0}] is never valid in an IPv4 address.
 http.illegalCharacterIpv6=The character [{0}] is never valid in an IPv6 address.
-http.invalidCharacterDomain=The character [{0}] is not valid{1} a domain name.
+http.invalidCharacterDomain.afterColon=The character [{0}] is not valid after a colon in a domain name.
+http.invalidCharacterDomain.afterHyphen=The character [{0}] is not valid after a hyphen in a domain name.
+http.invalidCharacterDomain.afterLetter=The character [{0}] is not valid after a letter in a domain name.
+http.invalidCharacterDomain.afterNumber=The character [{0}] is not valid after a number in a domain name.
+http.invalidCharacterDomain.afterPeriod=The character [{0}] is not valid after a period in a domain name.
+http.invalidCharacterDomain.atEnd=The character [{0}] is not valid at the end of a domain name.
+http.invalidCharacterDomain.atStart=The character [{0}] is not valid at the start of a domain name.
 http.invalidHextet=Invalid hextet. A hextet must consist of 4 or less hex characters.
 http.invalidIpv4Location=The IPv6 address contains an embedded IPv4 address at an invalid location.
 http.invalidLeadingZero=A non-zero IPv4 octet may not contain a leading zero.
diff --git a/java/org/apache/tomcat/util/http/parser/LocalStrings_fr.properties b/java/org/apache/tomcat/util/http/parser/LocalStrings_fr.properties
index 92f8347..62e9d75 100644
--- a/java/org/apache/tomcat/util/http/parser/LocalStrings_fr.properties
+++ b/java/org/apache/tomcat/util/http/parser/LocalStrings_fr.properties
@@ -23,6 +23,13 @@ http.illegalAfterIpv6=Le caractère [{0}] n''est pas permis dans un nom d''hôte
 http.illegalCharacterDomain=Le caractère [{0}] n''est jamais valide pour un nom de domaine
 http.illegalCharacterIpv4=Le caractère [{0}] n''est pas valide pour une adresse IPV4.
 http.illegalCharacterIpv6=Le caractère [{0}] n''est jamais valide dans une adresse IPv6
+http.invalidCharacterDomain.afterColon=Le caractère [{0}] n''est pas valide après deux-point pour un nom de domaine
+http.invalidCharacterDomain.afterHyphen=Le caractère [{0}] n''est pas valide après un trait d''union pour un nom de domaine
+http.invalidCharacterDomain.afterLetter=Le caractère [{0}] n''est pas valide après une lettre pour un nom de domaine
+http.invalidCharacterDomain.afterNumber=Le caractère [{0}] n''est pas valide après un nombre pour un nom de domaine
+http.invalidCharacterDomain.afterPeriod=Le caractère [{0}] n''est pas valide après une virgule pour un nom de domaine
+http.invalidCharacterDomain.atEnd=Le caractère [{0}] n''est pas valide à la fin d''un nom de domaine
+http.invalidCharacterDomain.atStart=Le caractère [{0}] n''est pas valide au début d''un nom de domaine
 http.invalidHextet="hextet" invalide.  Un "hextet" doit consister au maximum de 4 caractères hexadécimaux.
 http.invalidIpv4Location=L'adresse IPv6 contient une adresse IPv4 incluse à un endroit invalide
 http.invalidLeadingZero=Un octet IPv4 non nul ne doit pas commencer par un zéro
diff --git a/java/org/apache/tomcat/util/http/parser/LocalStrings_ja.properties b/java/org/apache/tomcat/util/http/parser/LocalStrings_ja.properties
index 46bc755..a8c8a8e 100644
--- a/java/org/apache/tomcat/util/http/parser/LocalStrings_ja.properties
+++ b/java/org/apache/tomcat/util/http/parser/LocalStrings_ja.properties
@@ -23,6 +23,13 @@ http.illegalAfterIpv6=文字[{0}]はホスト名のIPv6アドレスに従うこ
 http.illegalCharacterDomain=文字 [{0}] をドメイン名に含めることはできません。
 http.illegalCharacterIpv4=文字 [{0}] は正常な IPv4 アドレスに利用できません。
 http.illegalCharacterIpv6=IPv6 アドレスに文字 [{0}] を使用することはできません。
+http.invalidCharacterDomain.afterColon=ドメイン名のコロンの後の文字[{0}]は無効です。
+http.invalidCharacterDomain.afterHyphen=ドメイン名のハイフンの後の文字[{0}]は無効です
+http.invalidCharacterDomain.afterLetter=文字 [{0}] はドメイン名に利用できません。
+http.invalidCharacterDomain.afterNumber=ドメイン名の数字の後の文字[{0}]は無効です。
+http.invalidCharacterDomain.afterPeriod=ドメイン名のピリオドの後の文字[{0}]は無効です。
+http.invalidCharacterDomain.atEnd=文字[{0}]はドメイン名の最後には無効です。
+http.invalidCharacterDomain.atStart=文字[{0}]はドメイン名の先頭には無効です。
 http.invalidHextet=不正な 16 進数文字列です。16 進数文字列に使用できるのは 4 文字以下の 16 進数だけです。
 http.invalidIpv4Location=IPv6 アドレスは不正な位置に埋め込み IPv4 アドレスを含んでいます。
 http.invalidLeadingZero=IPv4 アドレスの 0 でないオクテットは先行する0を含まないかもしれません。
diff --git a/java/org/apache/tomcat/util/http/parser/LocalStrings_ko.properties b/java/org/apache/tomcat/util/http/parser/LocalStrings_ko.properties
index 2a06496..f882ac4 100644
--- a/java/org/apache/tomcat/util/http/parser/LocalStrings_ko.properties
+++ b/java/org/apache/tomcat/util/http/parser/LocalStrings_ko.properties
@@ -24,6 +24,13 @@ http.illegalAfterIpv6=호스트 이름 내에서, IPv6 주소 이후에 문자 [
 http.illegalCharacterDomain=문자 [{0}]은(는) 도메인 이름 내에서 유효하지 않은 문자입니다.
 http.illegalCharacterIpv4=문자 [{0}]은(는) IPv4 주소에서 절대 유효하지 않은 것입니다.
 http.illegalCharacterIpv6=문자 [{0}]은(는) IPv6 주소 내에서 유효하지 않은 것입니다.
+http.invalidCharacterDomain.afterColon=도메인 이름 내에서, 콜론 이후의 문자 [{0}]은(는) 유효하지 않습니다.
+http.invalidCharacterDomain.afterHyphen=도메인 이름 내에서, 붙임표(하이픈) 이후의 문자 [{0}]은(는) 유효하지 않습니다.
+http.invalidCharacterDomain.afterLetter=도메인 이름 내에서, 한 글자 이후의 문자 [{0}]은(는) 유효하지 않습니다.
+http.invalidCharacterDomain.afterNumber=도메인 이름 내에서, 숫자 이후의 문자 [{0}]은(는) 유효하지 않습니다.
+http.invalidCharacterDomain.afterPeriod=도메인 이름 내에서, 마침표 이후의 문자 [{0}]은(는) 유효하지 않습니다.
+http.invalidCharacterDomain.atEnd=도메인 이름의 끝 위치에, 문자 [{0}]은(는) 유효하지 않습니다.
+http.invalidCharacterDomain.atStart=도메인 이름의 시작 위치에, 문자 [{0}]은(는) 유효하지 않습니다.
 http.invalidHextet=유효하지 않은 헥스텟(hextet)입니다. 헥스텟은 반드시 네 개 이하의 문자들이어야 합니다.
 http.invalidIpv4Location=IPv6 주소가, 유효하지 않은 위치에 내장 IPv4 주소를 포함하고 있습니다.
 http.invalidLeadingZero=IPv4 옥텟(octet)은, 값이 0이 아닌 이상, 0으로 시작해서는 안됩니다.
diff --git a/java/org/apache/tomcat/util/http/parser/LocalStrings_zh_CN.properties b/java/org/apache/tomcat/util/http/parser/LocalStrings_zh_CN.properties
index 504b435..770e003 100644
--- a/java/org/apache/tomcat/util/http/parser/LocalStrings_zh_CN.properties
+++ b/java/org/apache/tomcat/util/http/parser/LocalStrings_zh_CN.properties
@@ -18,6 +18,13 @@ cookie.valueNotPresent=<不存在>
 http.closingBracket=在非IPv6主机名中找到了右括号']'。
 http.illegalCharacterIpv4=字符[{0}]为非法的IPv4地址。
 http.illegalCharacterIpv6=字符[{0}]为非法的IPv6地址。
+http.invalidCharacterDomain.afterColon=字符 [{0}] 在域名中的冒号后无效。
+http.invalidCharacterDomain.afterHyphen=字符 [{0}] 在域名中的连字符后无效。
+http.invalidCharacterDomain.afterLetter=字符 [{0}] 在域名中的字母后无效。
+http.invalidCharacterDomain.afterNumber=字符 [{0}] 在域名中的数字后无效。
+http.invalidCharacterDomain.afterPeriod=字符 [{0}] 在域名中的句号后无效。
+http.invalidCharacterDomain.atEnd=字符 [{0}] 在域名末尾无效。
+http.invalidCharacterDomain.atStart=字符 [{0}] 在域名开头无效。
 http.invalidHextet=hextet无效。 hextet必须包含4个或更少的十六进制字符。
 http.invalidIpv4Location=IPv6地址在无效位置包含嵌入的IPv4地址。
 http.invalidLeadingZero=非零的IPv4字符可能不包含前导零。
diff --git a/webapps/docs/config/ajp.xml b/webapps/docs/config/ajp.xml
index f16c443..93ed918 100644
--- a/webapps/docs/config/ajp.xml
+++ b/webapps/docs/config/ajp.xml
@@ -502,7 +502,9 @@
       </attribute>
       <attribute name="socket.txBufSize" required="false">
         <p>(int)The socket send buffer (SO_SNDBUF) size in bytes. JVM default
-        used if not set.</p>
+        used if not set. Care should be taken if explicitly setting this value.
+        Very poor performance has been observed on some JVMs with values less
+        than ~8k.</p>
       </attribute>
       <attribute name="socket.tcpNoDelay" required="false">
         <p>(bool)This is equivalent to standard attribute
diff --git a/webapps/docs/config/http.xml b/webapps/docs/config/http.xml
index 1031514..3252eba 100644
--- a/webapps/docs/config/http.xml
+++ b/webapps/docs/config/http.xml
@@ -677,7 +677,9 @@
       </attribute>
       <attribute name="socket.txBufSize" required="false">
         <p>(int)The socket send buffer (SO_SNDBUF) size in bytes. JVM default
-        used if not set.</p>
+        used if not set. Care should be taken if explicitly setting this value.
+        Very poor performance has been observed on some JVMs with values less
+        than ~8k.</p>
       </attribute>
       <attribute name="socket.tcpNoDelay" required="false">
         <p>(bool)This is equivalent to standard attribute


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org