Browse Source

A compromise between DDoS defense and Owncloud's web interface

Bob Mottram 10 years ago
parent
commit
6ccf68e0ab
1 changed files with 2 additions and 1 deletions
  1. 2
    1
      install-freedombone.sh

+ 2
- 1
install-freedombone.sh View File

3018
   echo '        limit_conn_zone $binary_remote_addr zone=conn_limit_per_ip:10m;' >> /etc/nginx/nginx.conf
3018
   echo '        limit_conn_zone $binary_remote_addr zone=conn_limit_per_ip:10m;' >> /etc/nginx/nginx.conf
3019
   echo '' >> /etc/nginx/nginx.conf
3019
   echo '' >> /etc/nginx/nginx.conf
3020
   echo '        # limit the number of requests for a given session' >> /etc/nginx/nginx.conf
3020
   echo '        # limit the number of requests for a given session' >> /etc/nginx/nginx.conf
3021
-  echo '        limit_req_zone $binary_remote_addr zone=req_limit_per_ip:10m rate=5r/s;' >> /etc/nginx/nginx.conf
3021
+  echo '        # Note that the Owncloud web interface seems to require a rate of around 140r/s' >> /etc/nginx/nginx.conf
3022
+  echo '        limit_req_zone $binary_remote_addr zone=req_limit_per_ip:10m rate=140r/s;' >> /etc/nginx/nginx.conf
3022
   echo '' >> /etc/nginx/nginx.conf
3023
   echo '' >> /etc/nginx/nginx.conf
3023
   echo '        # if the request body size is more than the buffer size, then the entire (or partial) request body is written into a temporary file' >> /etc/nginx/nginx.conf
3024
   echo '        # if the request body size is more than the buffer size, then the entire (or partial) request body is written into a temporary file' >> /etc/nginx/nginx.conf
3024
   echo '        client_body_buffer_size  128k;' >> /etc/nginx/nginx.conf
3025
   echo '        client_body_buffer_size  128k;' >> /etc/nginx/nginx.conf