HTTP header fields are components of the message header of requests and responses in the Hypertext Transfer Protocol (HTTP). They define the operating parameters of an HTTP transaction.

learn more… | top users | synonyms

0
votes
0answers
9 views

How can the HSTS header be added to WebLogic?

Is there an implementation for using the Strict-Transport-Security header to WebLogic? I figure it would be using something in web.xml under <security-constraint> I know how to do this for an ...
0
votes
0answers
9 views

Apache header order

I am working on a private server application for a web based mobile game that uses php to generate responses. In order to do this I am trying to replicate the behavior of the main server as closely as ...
0
votes
0answers
72 views

apache2 ubuntu 14.04. Expire date has been set, but it is not cached anyway

As shown in screenshot, the expire date is 11 May 2016 (a year from now), but the resource is always downloaded everytime I access the website. I set expire date by using htaccess: <IfModule ...
2
votes
3answers
210 views

How do I add no-cache headers to all 404 pages served by apache and nginx?

I have recently run into an issue after switching to Cloudflare, and the solution is to basically stop Cloudflare from caching 404 responses. In our load-balanced multi-server setup, occasional 404s ...
-1
votes
1answer
58 views

The server committed a protocol violation. Section=ResponseHeader Detail=CR must be followed by LF [closed]

I've tested my website with mxtoolbox.com and got this message: Result: The server committed a protocol violation. Section=ResponseHeader Detail=CR must be followed by LF I've googled around ...
1
vote
1answer
30 views

Is there a way to make GoogleImageProxy honor Cache-Control / expiration headers?

I am suddenly getting flooded with requests from Google's image proxy servers that look like the following: 66.249.81.250 - - [04/May/2015:06:55:54 +0000] "GET /images/image_1.jpg HTTP/1.1" 200 93394 ...
6
votes
2answers
58 views

Does Nginx `if_modified_since` only work on static resources?

I can't seem to find enough documentation. I have an app that generates some dynamic responses, but could still benefit from the Last-Modified header -- so I send it. However, turning on ...
1
vote
1answer
23 views

Unable to combine RewriteRule and Header set [duplicate]

Trying to implement the following: RewriteRule \.ttf$ - [E=cors:1] Header set Access-Control-Allow-Origin "*.example.com" env=cors:1 Header set Access-Control-Allow-Origin "*.sadface.com" env=!cors:1 ...
0
votes
0answers
33 views

HTTP response returns valid content-length header but no message body

I've recently found a very strange problem which I can't explain. After posting a HTTP request to our server occasionally the following response will occur: HTTP/1.1 200 OK Date: Mon, 13 Apr 2015 ...
2
votes
2answers
32 views

What's the purpose of spammy HTTP referers?

In the logs of my website, there's a lot of visits with a HTTP referer set to spam-like websites (usually Russian sites, I've noticed). I assume what they're doing is just using a web crawler to visit ...
1
vote
0answers
24 views

Date Header always has the same date

I have a server running Windows 2012 with IIS 8.5 that is hosting several sites. For every response that is returned from a client request to any of the sites the Date header has the same value: Key ...
0
votes
0answers
134 views

Error: No 'Access-Control-Allow-Origin' header is present on the requested resource. (NGINX)

I am using NGINX and I am receiving that error in the browser's console. I am so frustrated. According to my boss, I need to set up cors which what I did and still I am getting the same error. This ...
0
votes
1answer
271 views

nginx proxy_pass rewrite of response header location

The aim of this nginx instance is to get GitLab and OpenWRT Luci to redirect through a reverse proxy. It's already working for several other websites, all which have a base url which seems to counter ...
0
votes
0answers
36 views

How to preserve the name of the remoteUser while reverse proxy?

I am using a software which enables me to log my operations and one the things it is loggin is the name of the remote user. Neverthless, I have a little problem since I am working on a secured ...
0
votes
0answers
29 views

Apache2 Header set Server unexpected result

I'm running Apache/2.4.7 on Ubuntu. I'm trying to get the response "Server" header to include a less verbose response. curl -I my.domain.com returns Server: Apache. I can live with that. But curl -I ...
0
votes
0answers
79 views

Is setting a Content Security Policy incompatible with Joomla's admin page?

I'd like to set a content security policy header for a Joomla website running on Apache 2.4 and served by Varnish. Using this configuration from h5bp and setting Header set Content-Security-Policy ...
0
votes
0answers
47 views

Amazon ELB + EC2 Header mismatch

Preamble: I have an AWS Elastic Load Balancer in front of a Single Amazon EC2 instance. I have 3 other EC2 instances sending requests via curl to the Load Balancer. Direct requests to the EC2 ip has ...
1
vote
1answer
182 views

Set Access-Control-Allow-Origin Header for specific URL that has a Query String

I'm asking this here as a last resort after trying different things / asking google / reading http://httpd.apache.org/docs/2.2/ I have the following in my apache2.conf # Allow cross domain fonts ...
0
votes
2answers
62 views

Decrypt a Header in Apache (HTTPD)

I've been asked to have a look at whether it's possible to decrypt a header during the processing of the request. The specific use case is to respond to the decrypted contents of the header by ...
1
vote
1answer
34 views

How to avoid duplication of add_header directives in nginx?

The documentation says this: These directives are inherited from the previous level if and only if there are no add_header directives defined on the current level. My problem is that I have ...
0
votes
0answers
60 views

Nginx: How to access my reverse proxied sites via separate subdirectories

I have 2 web applications that I want available under http://example.com/demo1 and http://example.com/demo2. My config below correctly reverse proxies to each site, and the site is mostly functional, ...
-1
votes
1answer
98 views

Mikrotik: Add HTTP Header Parameter to Requests [duplicate]

I want to add a parameter of MikroTik to all HTTP header requests using MikroTik. So all client and servers that connected to the MikroTik can trace the parameter in their HTTP header. How can I ...
2
votes
1answer
214 views

What is the meaning of an IIS http status code 404.503?

Microsoft lists the IIS http status codes including the substatus codes here. In the 404 section there are substatus codes between 0 and 20, but in my logs I get a 503 as sc-substatus I can't find ...
1
vote
0answers
56 views

HAProxy: Limmit concurrent connections based on HTTP header field

I try to limit the number of concurrent connections using HAProxy stick-tables based on HTTP header fields. I could find plenty of examples using IP addresses, but this doesn't work in my case. Our ...
1
vote
0answers
32 views

Script to verify/monitior HTTP caching headers [closed]

We'd like to verify that all our websites use the correct HTTP caching headers. Is there a script out there to make a request to a website, check its response headers and report whether it will be ...
2
votes
2answers
218 views

Redirect depending on preferred language (Accept-Language) with .htaccess

When users request /, I want to redirect them to /en or /de, depending on their preference specified in the HTTP request header Accept-Language. I guess this is easy with server-side scripting, but I ...
0
votes
1answer
137 views

HEAD requests from Linux/Ubuntu boxes

I don't know if this falls under server fault. We have HEAD requests disabled on our server. But we see thousands of HEAD requests, always with the same user agent. 'X11; Linux x86_64 chrome. It ...
1
vote
0answers
91 views

Partial content 206 requests on nginx behind WebAuth

I'm having a troubleshooting an issue that I think is likely due to WebAuth authentication when serving .webm videos. The server I have is nginx 1.6.2. I can make 200 GET requests just fine. I also ...
3
votes
0answers
414 views

Haproxy: reject traffic by user agent from file

I am trying to reject connections from specific user agents (by matching a substring of the user-agent header) using an haproxy ACL with -f option to read from a file. However it is not working, it ...
0
votes
1answer
153 views

Configure Server to Initiate Http Keep-Alive

I have a set of clients that aren't including an http keep-alive header in their requests to my server. If I use something like Varnish to filter the incoming requests and add the keep-alive header ...
0
votes
1answer
162 views

NGiNX Custom Cache param based on regex match

My question(s) are as follows: How do I set custom variables based on regexp against a useragent? How do I set custom headers for the reverse-proxy request? How do I use these values as caching ...
0
votes
0answers
50 views

Enable charset header in nginx 301

I have nginx redirecting http requests to https. Currently the header in the redirect is Content-Type: text/html. I want it to be Content-Type: text/html;charset=utf-8. Here it says I need a custom ...
1
vote
2answers
377 views

Is it possible to set SSL/TLS version HTTP header with Apache which an backend application can use?

There is one service on a virtual machine with a dedicated IP that required to be accessible via SSLv3 (WinXP with IE6 clients). I moved that service several several years ago to a that virtual ...
0
votes
0answers
127 views

Set Headers for JSON in Apache proxy

Hello I try set header JSON in Apache proxy. I need this for test login in website. Below I put my apache config. <VirtualHost *:80> ServerName zx.xxxxxxx.xxxxxx.fr ServerAdmin ...
0
votes
0answers
28 views

Setting an Apache header's value based on a mapping?

Suppose I have an environment variable REMOTE_ROLES having a comma-separated list of value(s), e.g., "A, B, C". I want to set an HTTP request header X-Remote-Roles to a comma-separated list of those ...
0
votes
2answers
348 views

With nginx serve a custom 404 page with header 404, without changing the browseraddress

How do I force nginx to serve a custom 404 page while responding with a 404 header, without changing the address of the browser so the user can easily retype? set $allowed 0; #(updated after ...
0
votes
2answers
182 views

Nginx silently dropping header lines that exceed 1128 bytes

I have Nginx set up as a reverse proxy to a uWSGI application (a Django app). Due to the nature of the content that the Django app is hosting, sometimes the URLs get long. Really long. Because of ...
-1
votes
1answer
173 views

Debug Nginx caching

I want to determine when I am getting cache hits or misses. Preferably, this would be a header, like X-Cache: HIT or X-Cache: MISS How can I do this with Nginx (a reverse proxy for the upstream ...
-1
votes
1answer
90 views

Does Nginx respect maxage from upstream server?

I see the proxy_cache_valid directive, but that confuses me. In HTTP, doesn't the upstream server specify this with Cache-Control and maxage? How do I get Nginx's cache to use maxage ?
-1
votes
1answer
62 views

Apache configuration redirect using only redirect, not rewrite

PS: this is the 2nd part of the question originally posted here. I'd like to disable the HSTS header completely for specific virtual hosts. I have (per recommendation) a redirect in the 443 container ...
-1
votes
1answer
65 views

Serve static files from directory depending on http referrer inside of nginx [closed]

My server hosts images, but the content of images have to be different for the same link and have to deepens on http referrer. For example: Website 1 load image website1.jpg from ...
1
vote
1answer
73 views

how to find out if mod_xsendfile is handling the transfer?

I just installed and configured mod_xsendfile on my apache2.2.15 web server (on centos6.5). Everything seems to be working fine except that I'm not sure it is. I added XSendFile On and XSendFilePath ...
2
votes
2answers
369 views

Apache HSTS exception for some virtual hosts

In the global config section for Apache 2.2.15, I have the following (per recommendation) <IfModule mod_headers.c> Header add Strict-Transport-Security "max-age=15768000;includeSubDomains" ...
0
votes
1answer
744 views

Nginx/Apache: set HSTS only if X-Forwarded-Proto is https

I got the following setup: Internet => nginx[public:80 +443, SSL termination) => Varnish[localhost:81] => Apache[localhost:82] Now some sites should only be reachable via HTTPS and a valid ...
2
votes
1answer
107 views

Conditionally serving high resolution and WebP images with nginx

Not sure if I'm trying to pull off the impossible, but I'm wanting to configure Nginx to serve ".webp" files to browsers that support the file format and serve fallback files (i.e. pngs, jpgs, etc.) ...
4
votes
2answers
2k views

The Content-Length header does not exist

I have nginx server installed on Linux. When I send a request with curl, the Content-Length header is missing from the response. The 1.php file is: <?php echo "hello"; ?> The example ...
0
votes
0answers
191 views

handling CORS preflight request in Apache

I have a AngularJS app deployed using Yeoman. Cakephp RESTful backend. The Angular app sends in OPTIONS preflight requests, which the backend responds with forbidden (403), in nginx to solve this ...
0
votes
0answers
127 views

Override PHP Cache-Control Header from Apache config?

PHP is setting the Cache-Control header in multiple places. I don't want to break my code upgrade path, but I'd like to change the Cache-Control header in Apache config instead. However, it looks like ...
0
votes
1answer
39 views

Measuring HTTP traffic basic on URIs and custom headers

I'm currently working on an API service and one of the requirements is that we measure the amount of data used by each user of the system, and track how many times they use the API. So bandwidth usage ...
0
votes
1answer
21 views

Is it possible to path protect by header values in apache?

Is there a mod / way to get this pseudo code working in apache? <Location /somepath/> if not value of request header 'x-token' is 'secret' deny </Location>