Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d4879b2
commit 35bb6c0
Showing
12 changed files
with
52 additions
and
96 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 0 additions & 7 deletions
7
ic-os/boundary-guestos/rootfs/etc/nginx/includes/cors_remove_proxy.conf
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 14 additions & 2 deletions
16
ic-os/boundary-guestos/rootfs/etc/nginx/includes/proxy_headers.conf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,28 @@ | ||
# Basic headers | ||
proxy_set_header Host $host; | ||
proxy_set_header X-Real-IP $remote_addr; | ||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | ||
proxy_set_header X-Forwarded-Proto $scheme; | ||
proxy_set_header X-Request-ID $request_uuid; | ||
proxy_set_header Connection ""; | ||
|
||
# Request-ID | ||
proxy_set_header X-Request-ID $request_uuid; | ||
|
||
# Remove CORS-related headers | ||
proxy_hide_header Access-Control-Allow-Origin; | ||
proxy_hide_header Access-Control-Allow-Methods; | ||
proxy_hide_header Access-Control-Allow-Credentials; | ||
proxy_hide_header Access-Control-Allow-Headers; | ||
proxy_hide_header Access-Control-Expose-Headers; | ||
proxy_hide_header Access-Control-Max-Age; | ||
|
||
# Headers used for logging | ||
proxy_hide_header x-ic-error-cause; | ||
proxy_hide_header x-ic-subnet-id; | ||
proxy_hide_header x-ic-cache-bypass-reason; | ||
proxy_hide_header x-ic-node-id; | ||
proxy_hide_header x-ic-request-type; | ||
proxy_hide_header x-ic-subnet-type; | ||
proxy_hide_header x-ic-canister-id; | ||
proxy_hide_header x-ic-sender; | ||
proxy_hide_header x-ic-retries; | ||
proxy_hide_header x-ic-method-name; |
5 changes: 0 additions & 5 deletions
5
ic-os/boundary-guestos/rootfs/etc/nginx/includes/proxy_keepalive.conf
This file was deleted.
Oops, something went wrong.
5 changes: 0 additions & 5 deletions
5
ic-os/boundary-guestos/rootfs/etc/nginx/includes/proxy_x_request_id.conf
This file was deleted.
Oops, something went wrong.
1 change: 1 addition & 0 deletions
1
ic-os/boundary-guestos/rootfs/etc/nginx/includes/request_id.conf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
# Response | ||
add_header X-Request-ID $request_uuid always; |
4 changes: 4 additions & 0 deletions
4
...estos/rootfs/etc/nginx/includes/cors.conf → .../etc/nginx/includes/response_headers.conf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,9 @@ | ||
# CORS | ||
add_header "Access-Control-Allow-Origin" "*" always; | ||
add_header "Access-Control-Allow-Methods" "$cors_allow_methods" always; | ||
add_header "Access-Control-Allow-Headers" "DNT,User-Agent,X-Requested-With,If-None-Match,If-Modified-Since,Cache-Control,Content-Type,Range,Cookie,X-Ic-Canister-Id" always; | ||
add_header "Access-Control-Expose-Headers" "Accept-Ranges,Content-Length,Content-Range,X-Request-Id,X-Ic-Canister-Id" always; | ||
add_header "Access-Control-Max-Age" "600" always; | ||
|
||
# Other | ||
add_header "X-Content-Type-Options" "nosniff" always; |
7 changes: 0 additions & 7 deletions
7
ic-os/boundary-guestos/rootfs/etc/nginx/includes/secure_headers.conf
This file was deleted.
Oops, something went wrong.