0
votes
2answers
641 views

Gzip compression with nginx

In my nginx.conf I have: gzip on; gzip_static on; gzip_buffers 16 8k; gzip_comp_level 9; gzip_http_version 1.0; gzip_min_length 1000; gzip_types text/plain text/css ...
0
votes
1answer
528 views

Content disposition header on Nginx

I am doing a setup where Apache runs the web application and NginX serves files that users download. The files should be downloaded with their real names instead of the names their are being stored ...
2
votes
2answers
879 views

nginx: Specify custom headers in rewritten location blocks

I'm trying to set some headers only for specific location blocks in nginx. The problem I have is that those location blocks contain rewrite statements, which apparently seem to drop the custom ...
2
votes
1answer
382 views

How to remove “Client-Peer” (etc) header in nginx with php-fastcgi

My setup: OS: Ubuntu 11.04 HTTP Server: nginx 1.2.1 compiled with the HttpHeadersMore module processing PHP via php-fastcgi (other irrelevant software - ruby, python, etc) My problem: I'm ...
1
vote
1answer
705 views

Content-length does not appear with nginx and php files

I have a nginx server which serve a website. With my browser i can reach index.php, but when i look at the headers with firebug, i can't see the content-length on any php files, but for example i can ...
2
votes
1answer
774 views

Hide/Replace Nginx Location Header?

I am trying to pass a PCI compliance test, and I'm getting a single "high risk vulnerability". The problem is described as: Information on the machine which a web server is located is sometimes ...
1
vote
2answers
582 views

NGINX Pass-through server header

How do I get NGINX to pass through the 'server' header of upstream servers? Like, if NGINX is proxying to an Apache server with the Server header 'Apache2.2 (CentOS)', it strips it out and replaces ...
9
votes
3answers
14k views

How can I make nginx support @font-face formats and allow access-control-allow-origin?

I've added these rules to mime.types: application/x-font-ttf ttf; font/opentype otf; application/vnd.ms-fontobject eot; font/x-woff ...
2
votes
1answer
1k views

Disable User-Agent based Vary header response in nginx?

It seems that nginx includes a Vary: Accept-Encoding header in some cases regardless of the file types I specify via "gzip_types". I do not have much experience with nginx. Does it in fact send Vary: ...
25
votes
5answers
27k views

Setting expires headers for static content served from nginx

I'm using nginx to server my static content, is there a way that I can set the expires headers for every file that meets a specific rule? For example can I set the expires header for all files that ...