8th Jul 2010
Code
Comments (0)

For anybody who is unaware, all default Apache2 installations on Ubuntu (and most other OSes) are vulnerable to a simple Slowloris DOS attack; any script kiddie with Perl and some free time can bring down major sites with limited bandwidth and resources, due to the way Apache handles half-open connections. Without going into how Slowloris works (that’s detailed on the Slowloris project page) or getting too complicated, here’s a simple way to effectively defend against this type of attack.

Run these commands (as root) and you’ll be good to go.

root:~# apt-get install libapache2-mod-antiloris
root:~# service apache2 restart

That’s it! While this module doesn’t offer complete protection—a sufficiently distributed attacker could probably still defeat this—it will stop most script kiddies and even somewhat determined attackers from using Slowloris on your servers.

Comments
 
Please keep comments (fairly) clean.

Text can be formatted with Markdown. No HTML please.