You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by David Dabbs <dm...@gmail.com> on 2011/11/23 16:34:09 UTC

[users@httpd] Removing request headers before a request is processed. . .

I'm using httpd in front of a Tomcat app server and would like to remove
some incoming cookies before requests are reverse-proxied to Tomcat. The
cookie names are not fixed, but do match several simple regexps. Is there a
recipe with mod_headers/mod_rewrite that would allow me to strip these
cookies before these requests are handled?

 

Thanks,

 

David

 


Re: [users@httpd] Removing request headers before a request is processed. . .

Posted by Igor Cicimov <ic...@gmail.com>.
It's already in the examples of mod_headers:

SetEnvIf MyRequestHeader myvalue HAVE_MyRequestHeader
Header set MyHeader "%D %t mytext" env=HAVE_MyRequestHeader

so you just need to midify it to something like this:

SetEnvIf MyRequestCookieHeader your_regexp_here HAVE_MyRequestCookieHeader
RequestHeader unset MyRequestCookieHeader env=HAVE_MyRequestCookieHeader



On Thu, Nov 24, 2011 at 2:34 AM, David Dabbs <dm...@gmail.com> wrote:

> I’m using httpd in front of a Tomcat app server and would like to remove
> some incoming cookies before requests are reverse-proxied to Tomcat. The
> cookie names are not fixed, but do match several simple regexps. Is there a
> recipe with mod_headers/mod_rewrite that would allow me to strip these
> cookies before these requests are handled?****
>
> ** **
>
> Thanks,****
>
> ** **
>
> David****
>
> ** **
>