Code Monkey home page Code Monkey logo

nginx-anti-ddos's Introduction

nginx-anti-ddos

This is my standard configuration I use to reduce the effectiveness of layer 7 ddos attacks.

What this alone can do?

This script alone can block small layer7 denial of service attacks. Once attacks get larger you'll have to take other measures to block the evil sources from connecting to your server.

So what about botnets? What do I do?

Well nginx can only process so many requests per second due to the limits of a single server. That being said there are a few things you can do. First if you are being attacked with frequent, large attacks, get the most powerful server you can afford (make sure it has powerful and multiple CPUs), second you should configure fail2ban to ban repeat infringers of your rate limits. I personally use fail2ban to issue Cloudflare IP Address Bans with their API. A botnet unfortently due to the size will hit of your site at first but within 5-15 minutes of the attack starting fail2ban SHOULD finish banning all of the evil IPs and your site will be back. At the moment I haven't published my fail2ban configs. I may do so later.

nginx-anti-ddos's People

Contributors

nsuchy avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.