Modified code as per review comment
@@ -15,7 +15,7 @@ server {
if ($ssl_protocol = "") {
return 308 https://$host$request_uri;
}
- if ($request_method !~ ^(GET|HEAD|POST)$ ) {
+ if ($request_method !~ ^(GET|HEAD|POST|PUT|DELETE)$ ) {
return 405;
}
index index.html;
@@ -27,6 +27,11 @@ server {
server {
listen *:443 ssl;
server_tokens off;
+
+ if ($request_method !~ ^(GET|HEAD|POST|PUT|DELETE)$ ) {
+ return 405;
+ }
+
ssl_certificate /etc/ssl/st2/st2.crt;
ssl_certificate_key /etc/ssl/st2/st2.key;
ssl_session_cache shared:SSL:10m;
@@ -70,6 +75,7 @@ server {
proxy_buffering off;
proxy_cache off;
proxy_set_header Host $host;
+ max_ranges 0;
}
location @streamError {
@@ -104,6 +110,7 @@ server {
chunked_transfer_encoding off;
proxy_buffering off;
proxy_cache off;
+ max_ranges 0;
}
location @authError {
@@ -131,14 +138,14 @@ server {
proxy_buffering off;
proxy_cache off;
proxy_set_header Host $host;
+ max_ranges 0;
}
location / {
+ max_ranges 0;
root /opt/stackstorm/static/webui/;
index index.html;
- proxy_set_header Range "";
-
sendfile on;
tcp_nopush on;
tcp_nodelay on;
