Return-Path: Delivered-To: apmail-tomcat-dev-archive@www.apache.org Received: (qmail 8382 invoked from network); 26 Nov 2010 07:04:31 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 26 Nov 2010 07:04:31 -0000 Received: (qmail 66272 invoked by uid 500); 26 Nov 2010 07:04:30 -0000 Delivered-To: apmail-tomcat-dev-archive@tomcat.apache.org Received: (qmail 66107 invoked by uid 500); 26 Nov 2010 07:04:30 -0000 Mailing-List: contact dev-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Developers List" Delivered-To: mailing list dev@tomcat.apache.org Received: (qmail 66098 invoked by uid 99); 26 Nov 2010 07:04:29 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 26 Nov 2010 07:04:29 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 26 Nov 2010 07:04:28 +0000 Received: from thor.apache.org (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id oAQ748Al012178 for ; Fri, 26 Nov 2010 07:04:08 GMT Received: (from daemon@localhost) by thor.apache.org (8.13.8+Sun/8.13.8/Submit) id oAQ747fI012176; Fri, 26 Nov 2010 02:04:07 -0500 (EST) Date: Fri, 26 Nov 2010 02:04:07 -0500 (EST) From: bugzilla@apache.org To: dev@tomcat.apache.org Subject: DO NOT REPLY [Bug 50342] New: Exception on the Host request-header field included colon(':') X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Tomcat 6 X-Bugzilla-Component: Connectors X-Bugzilla-Keywords: X-Bugzilla-Severity: minor X-Bugzilla-Who: knight@nhn.com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: dev@tomcat.apache.org X-Bugzilla-Target-Milestone: default X-Bugzilla-Changed-Fields: Message-ID: X-Bugzilla-URL: https://issues.apache.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 https://issues.apache.org/bugzilla/show_bug.cgi?id=3D50342 Summary: Exception on the Host request-header field included colon(':') Product: Tomcat 6 Version: 6.0.26 Platform: PC Status: NEW Severity: minor Priority: P2 Component: Connectors AssignedTo: dev@tomcat.apache.org ReportedBy: knight@nhn.com Hello. If A tomcat receive a request contained the Host request-header field inclu= ded colon, java.io.CharConversionException is thrown. Exception is below 2010. 11. 26 SEVERE 3:43:37 org.apache.jk.common.HandlerRequest invoke SEVERE: Error decoding request=20 java.io.CharConversionException: Invalid char in port: 103 at org.apache.jk.common.HandlerRequest.parseHost(HandlerRequest.java:655) at org.apache.jk.common.HandlerRequest.decodeRequest(HandlerRequest.java:403) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:2= 60) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:754) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:684) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.jav= a:876) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.ja= va:684) at java.lang.Thread.run(Thread.java:619) 2010. 11. 26 SEVERE 3:43:37 org.apache.jk.common.ChannelSocket processConnection SEVERE=C3=AD: processCallbacks status 2 2010. 11. 26SEVERE 3:43:37 org.apache.jk.common.HandlerRequest invoke SEVERE: Error decoding request=20 java.io.CharConversionException: Invalid char in port: 103 at org.apache.jk.common.HandlerRequest.parseHost(HandlerRequest.java:655) at org.apache.jk.common.HandlerRequest.decodeRequest(HandlerRequest.java:403) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:2= 60) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:754) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:684) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.jav= a:876) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.ja= va:684) at java.lang.Thread.run(Thread.java:619) 2010. 11. 26 SEVERE 3:43:37 org.apache.jk.common.ChannelSocket processConnection SEVERE=C3=AD: processCallbacks status 2 So. the sample request is below : (Host field contained two domain name ; tomcat.apache.org and www.apache.or= g) telnet localhost 80 Trying 127.0.0.1... Connected to localhost.localdomain (127.0.0.1). Escape character is '^]'. GET http://myweb.com/search.nhn HTTP/1.1 Accept-Language: ko-KR User-Agent: Mozilla/4.0 Accept-Encoding: gzip, deflate Host: tomcat.apache.org:www.apache.org=20=20=20 Connection: Keep-Alive HTTP/1.1 502 Bad Gateway Date: Fri, 26 Nov 2010 06:43:36 GMT ..... It looks like the HTTP 1.1 specification allows to do such call, here's the content of HTTP 1.1 specification. http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.23 14.23 Host The Host request-header field specifies the Internet host and port number of the resource being requested, as obtained from the original URI given by the user or referring resource (generally an HTTP URL,=20 as described in section 3.2.2). The Host field value MUST represent the nam= ing authority of the origin server or gateway given by the original URL. This allows the origin server or gateway to differentiate between internally-ambiguous URLs, such as the root "/" URL of a server for multiple host names on a single IP address.=20 Host =3D "Host" ":" host [ ":" port ] ; Section 3.2.2 Because http specification 1.1 support multiple host name, I think tomcat m= ay support this. If I am wrong, let me know it.=20 Every tomcat I tested show the exception.=20 Thank you. --=20 Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=3De= mail ------- You are receiving this mail because: ------- You are the assignee for the bug.= --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org For additional commands, e-mail: dev-help@tomcat.apache.org