Return-Path: Delivered-To: apmail-tomcat-dev-archive@www.apache.org Received: (qmail 66871 invoked from network); 29 Dec 2006 23:41:54 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 29 Dec 2006 23:41:54 -0000 Received: (qmail 31385 invoked by uid 500); 29 Dec 2006 23:41:58 -0000 Delivered-To: apmail-tomcat-dev-archive@tomcat.apache.org Received: (qmail 30770 invoked by uid 500); 29 Dec 2006 23:41:56 -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 30759 invoked by uid 500); 29 Dec 2006 23:41:56 -0000 Delivered-To: apmail-jakarta-tomcat-dev@jakarta.apache.org Received: (qmail 30756 invoked by uid 99); 29 Dec 2006 23:41:55 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 29 Dec 2006 15:41:55 -0800 X-ASF-Spam-Status: No, hits=-9.4 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 29 Dec 2006 15:41:48 -0800 Received: by brutus.apache.org (Postfix, from userid 33) id 6C7EB7141D1; Fri, 29 Dec 2006 15:41:28 -0800 (PST) From: bugzilla@apache.org To: tomcat-dev@jakarta.apache.org Subject: DO NOT REPLY [Bug 41263] New: - servletRequest.getRemotePort() returns incorrect value when behind mod_jk Message-ID: X-Bugzilla-Reason: AssignedTo Date: Fri, 29 Dec 2006 15:41:28 -0800 (PST) X-Virus-Checked: Checked by ClamAV on apache.org DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG� RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT . ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND� INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=41263 Summary: servletRequest.getRemotePort() returns incorrect value when behind mod_jk Product: Tomcat 5 Version: 5.5.20 Platform: Other OS/Version: All Status: NEW Severity: normal Priority: P2 Component: Native:JK AssignedTo: tomcat-dev@jakarta.apache.org ReportedBy: clamprecht@gmail.com Access the following short test JSP running on a tomcat behind mod_jk and Apache: <% out.println("Your IP is "+request.getRemoteAddr()+", your port is "+request.getRemotePort()); %> It returns either 0 or -1 for the remote port. It seems to return 0 the first time, and -1 for any subsequent request which is on the same underlying keepalive connection. The desired behaviour would be that it returns the actual remote port that the client connected from (on the client's machine), when available. In other words, it should behave the same as when you access the JSP through tomcat directly through an HTTP connector (via port 8080 on a default tomcat install, for instance). I understand this information will not always be available, for instance, when running behind a proxy. But in the case of running behind mod_jk, shouldn't this information be available, since the remote IP number is already available? -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org For additional commands, e-mail: dev-help@tomcat.apache.org