Questions tagged [mod-headers]

An Apache module which provides directives to control and modify HTTP request and response headers.

109 questions
0
votes
1 answer

apache stdenvvars doesn't work inside location

I'm developing a x509 authentication with apache and symfony2. My symfony aplication has also authentication with login/password on '/login' path, and I would like to configure a location in '/login_x509'. This is my apache…
0
votes
2 answers

Apache's RequestHeader is ineffective and effect is not seen in .htaccess

This is an apache question. I set a header in my config files with RequestHeader. (local apache install) I can see that works as per the output of a custom php script to dump headers: the header is there. However a rule based on that header being…
0
votes
1 answer

Apache mod-headers - keep only specific cookies

I am trying to use a "RequestHeader edit" directive to manipulate the "Cookie" header and only keep a specific set of cookies from that header. RequestHeader edit Cookie "PATTERN TO REMOVE ALL COOKIES DESPITE OF .."…
Felix
  • 3
  • 1
0
votes
1 answer

How add to .htaccess condition like this?

Need add to .htaccess condition like this: if (page == '/admin') { Header add Test "test" } This is not working: Header add Test "test" But this working on…
wagwandude
  • 59
  • 5
0
votes
1 answer

modpagespeed overrides cachecontrol of static content in apache

currently the version 1.9.32.14-r0 of mod_pagespeed running on the webserver purely static content (not pagespeed cached) is served with first max-age=300 and counting downward to max-age=0 and starting again with max-age=300 when mod_pagespeed is…
0
votes
1 answer

How to proxy part of old website via new in Apache 2.4

The old website must operate under www.domain.com / remain live during development. The old website runs forum software that has urls deeply embedded that make it believe it's www.domain.com - and its config produces links with absolute urls…
math
  • 151
  • 3
0
votes
1 answer

Magento keep alive response: connection close

I am trying to add a KeepAlive statement to my htaccess. I've set it like this: Header set Connection keep-alive I i tested this, I got the response close on the connection! Does someone know how to resolve…
aelhobbi
  • 39
  • 1
  • 15
0
votes
1 answer

How to Add request headers for modify header in selenium with ruby on chrome web browser

I am trying to add request headers for modHeaders in chrome through Selenium with ruby. I have tried this code but no luck. Mod Header extension has added to browser but unable to add request headers to that extension. Please help me to find the…
0
votes
1 answer

Why `mod_headers` cannot match based on the content-type?

I can't get my mind wrapped around the comments and way of coding, to set a header only for .html in for example the .htaccess file in html5 boilerplate. The clue for a big codeblock lays in the fact that 'mod_headers can't match on the content…
E.C.Pabon
  • 265
  • 1
  • 9
0
votes
1 answer

Apache mod_header strange behavior

############################ # FILES - CACHING: CONTROL # ############################ Header set Cache-Control "max-age=2592000, public" Header set Cache-Control…
Tommaso Belluzzo
  • 23,232
  • 8
  • 74
  • 98
0
votes
1 answer

RequestHeder not getting other variables values

I have a request that contains the header X-Client-Cert and I need to assign it to another header from the virtual host configuration in apache. How can I do that? RewriteEngine On RequestHeader set NewHeader "%{X-Client-Cert}e" Thist solution…
0
votes
1 answer

Add Expires headers on Yslow doesn't have any effect

I have mod_expires and mod_headers enabled on the server and this code in htaccess: AddDefaultCharset UTF-8 Header set Content-Language "en-US" Header set Vary…
vld1
  • 9
  • 8
0
votes
0 answers

Changing a REST service response content-type with mod_rewrite

To work around a IE8 compatibility issue, I would like to change the content-type of a REST service response without changing my application source code. I'm trying to do this with a mod_rewrite rule: RewriteCond %{HTTP_USER_AGENT}…
awbp
  • 1
  • 1
0
votes
1 answer

Puppet configuration for apache2 with mod_headers

I'm configuring a Vagrant box (Ubuntu) with a puppet manifest - Everything is working except when I visit a site on the Vagrant host I get an error: Invalid command 'Header' Which I believe is due to Apache's mod_header not being loaded. The puppet…
user4984
  • 105
  • 5
0
votes
1 answer

apache rule to transform x-storage-url to X-Storage-Url

We are looking for a Apache rule to transform x-storage-url to X-Storage-Url in the http response header. alternatively to add (if that's possible) an "X-Storage-Url" header whenever you find an "x-storage-url" header and use the same header…
Saqib Ali
  • 3,953
  • 10
  • 55
  • 100