Return-Path: Delivered-To: apmail-jakarta-tomcat-user-archive@apache.org Received: (qmail 8375 invoked from network); 11 Apr 2003 19:59:39 -0000 Received: from exchange.sun.com (192.18.33.10) by daedalus.apache.org with SMTP; 11 Apr 2003 19:59:39 -0000 Received: (qmail 17458 invoked by uid 97); 11 Apr 2003 20:01:37 -0000 Delivered-To: qmlist-jakarta-archive-tomcat-user@nagoya.betaversion.org Received: (qmail 17451 invoked from network); 11 Apr 2003 20:01:37 -0000 Received: from daedalus.apache.org (HELO apache.org) (208.185.179.12) by nagoya.betaversion.org with SMTP; 11 Apr 2003 20:01:37 -0000 Received: (qmail 5203 invoked by uid 500); 11 Apr 2003 19:59:04 -0000 Mailing-List: contact tomcat-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Tomcat Users List" Reply-To: "Tomcat Users List" Delivered-To: mailing list tomcat-user@jakarta.apache.org Received: (qmail 19951 invoked from network); 11 Apr 2003 15:56:44 -0000 In-Reply-To: <9C5166762F311146951505C6790A9CF858E886@US-VS1.corp.mpi.com> To: "Tomcat Users List" Subject: RE: How to remove http headers? MIME-Version: 1.0 X-Mailer: Lotus Notes Release 6.0.1 February 07, 2003 Message-ID: From: =?ISO-8859-1?Q?Kristj=E1n_Bjarni_Gu=F0mundsson?= Date: Fri, 11 Apr 2003 15:56:06 +0000 X-MIMETrack: Serialize by Router on Office/REK/Hugvit(Release 6.0.1|February 07, 2003) at 11.04.2003 15:56:08, Serialize complete at 11.04.2003 15:56:08 Content-Type: multipart/alternative; boundary="=_alternative 0057882200256D05_=" X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N --=_alternative 0057882200256D05_= Content-Type: text/plain; charset="US-ASCII" "Shapira, Yoav" wrote on 11.04.2003 12:55:17: > Howdy, > > >Tomcat seems to automatically add these header to the response: > > > >Pragma: No-cache > >Cache-Control: no-cache > >Expires: Thu, 01 Jan 1970 00:00:00 GMT > > Tomcat doesn't automatically add these AFAIK, except possibly the 3rd > header. > > My guess is something else in your network adds these. I beg to differ. I am running the server and browser on the same machine and I am using TCPMonitor to examine the connection. I am using Apache Tomcat/4.1.24-LE-jdk14. This does not happen with normal unsecure files, only secure files. You can test this yourself with for example the manager application. > >So how can I do that? There is no removeHeader() function in the > servlet > >api. > > There's no removeHeader, but there's addHeader, which you can use > multiple times, overriding the old value if it exists. So you can add a > "Pragma" header with "cache-always" or whatever other value you want, > overriding the above. Well "Cache-Control" is no problem I can modify that to "public" or "private" However "Pragma" has only one valid value: "no-cache" So you really can't modify it to something else. And also any of this isn't really useful when there is also an "Expires" header and I can't modify that value since I have no idea when the file will expire in the future. --=_alternative 0057882200256D05_=--