[download-web/mirrorbits] nginx: Use http_x_forwarded_for as origin IP
- From: Bartłomiej Piotrowski <bpiotrowski src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [download-web/mirrorbits] nginx: Use http_x_forwarded_for as origin IP
- Date: Tue, 8 Dec 2020 08:17:11 +0000 (UTC)
commit 9770bdb9115dbfc5998e84f2b317d51140b5744c
Author: Bartłomiej Piotrowski <bpiotrowski gnome org>
Date: Tue Dec 8 09:17:06 2020 +0100
nginx: Use http_x_forwarded_for as origin IP
nginx/nginx.conf | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/nginx/nginx.conf b/nginx/nginx.conf
index b512a0a..71428c7 100644
--- a/nginx/nginx.conf
+++ b/nginx/nginx.conf
@@ -43,9 +43,9 @@ http {
}
location / {
- proxy_set_header X-Forwarded-For $remote_addr;
+ proxy_set_header X-Forwarded-For $http_x_forwarded_for;
proxy_set_header Host $host;
- proxy_set_header X-Real-IP $remote_addr;
+ proxy_set_header X-Real-IP $http_x_forwarded_for;
proxy_buffering off;
proxy_pass http://127.0.0.1:8080;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]