]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/tilecache/templates/default/nginx_tile.conf.erb
tilecache: limit supported request methods
[chef.git] / cookbooks / tilecache / templates / default / nginx_tile.conf.erb
index 6e964e157670156eb861e2ece0fae44808bdeb51..bc41ffbafde50670ba3dd1caec20109d845da097 100644 (file)
@@ -105,6 +105,11 @@ server {
     # See: http://nginx.org/en/docs/http/ngx_http_ssl_module.html#ssl_early_data
     ssl_early_data on;
 
+    # Only allow GET / HEAD / OPTIONS (CORS) requests
+    limit_except GET HEAD OPTIONS {
+      deny all;
+    }
+
     # Immediately 404 layers we do not support
 <% for i in 20..99 do %>
     location /<%= i %>/ {