Return-Path: Delivered-To: apmail-jakarta-tomcat-dev-archive@apache.org Received: (qmail 84852 invoked from network); 22 Jul 2003 01:36:36 -0000 Received: from exchange.sun.com (192.18.33.10) by daedalus.apache.org with SMTP; 22 Jul 2003 01:36:36 -0000 Received: (qmail 8011 invoked by uid 97); 22 Jul 2003 01:39:15 -0000 Delivered-To: qmlist-jakarta-archive-tomcat-dev@nagoya.betaversion.org Received: (qmail 8004 invoked from network); 22 Jul 2003 01:39:15 -0000 Received: from daedalus.apache.org (HELO apache.org) (208.185.179.12) by nagoya.betaversion.org with SMTP; 22 Jul 2003 01:39:15 -0000 Received: (qmail 84044 invoked by uid 500); 22 Jul 2003 01:36:29 -0000 Mailing-List: contact tomcat-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Tomcat Developers List" Reply-To: "Tomcat Developers List" Delivered-To: mailing list tomcat-dev@jakarta.apache.org Received: (qmail 84022 invoked from network); 22 Jul 2003 01:36:29 -0000 Received: from nwkea-mail-1.sun.com (192.18.42.13) by daedalus.apache.org with SMTP; 22 Jul 2003 01:36:29 -0000 Received: from phys-d3-ha21sca-1 ([129.145.155.163]) by nwkea-mail-1.sun.com (8.12.9/8.12.9) with ESMTP id h6M1acUg005721 for ; Mon, 21 Jul 2003 18:36:38 -0700 (PDT) Received: from sun.com (sr-usfo06-02.Eng.Sun.COM [129.144.83.35]) by ha21sca-mail1.sfbay.sun.com (iPlanet Messaging Server 5.2 HotFix 1.10 (built Jan 23 2003)) with ESMTP id <0HIE0098YKH1IX@ha21sca-mail1.sfbay.sun.com> for tomcat-dev@jakarta.apache.org; Mon, 21 Jul 2003 18:36:38 -0700 (PDT) Date: Mon, 21 Jul 2003 18:36:37 -0700 From: Jan Luehe Subject: Re: cvs commit: jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/servlet JspServlet.java To: Tomcat Developers List Reply-to: Jan.Luehe@Sun.COM Message-id: <3F1C9525.1000605@sun.com> MIME-version: 1.0 Content-type: text/plain; format=flowed; charset=us-ascii Content-transfer-encoding: 7bit X-Accept-Language: en-US User-Agent: Mozilla/5.0 (X11; U; SunOS sun4u; en-US; rv:1.1) Gecko/20020827 References: <20030721190635.2717.qmail@icarus.apache.org> <3F1C3BF5.20701@apache.org> X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N >> + >> + /* >> + * Add X-Powered-By header for JSP, if Catalina already >> added a >> + * corresponding header for servlets >> + */ >> + if (response.containsHeader("X-Powered-By")) { >> + response.addHeader("X-Powered-By", "JSP/2.0"); >> + } >> + > > > This is a pretty bad implementation IMO. > What's the use of disabling this feature ? The spec declares these headers as optional, which means Tomcat should make them configurable. Some sites may prefer not to include this information in their responses, for security reasons or whatever. > -1 on the various flags and checks (just add the headers, without flags > and complexity). -0 if you can indicate a good reason for this. > Also, you shouldn't add the JSP 2.0 header in JspServlet. If you > precompile, it's not called. Put it in HttpJspBase. I had thought about adding the JSP 2.0 header in HttpJspBase, but then realized that the "extends" page directive allows you to specify the class that the generated servlet should extend, in which case HttpJspBase will be out of the picture. Do you have a better idea? Jan --------------------------------------------------------------------- To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org