Gentoo Archives: gentoo-user

From: Michael Mol <mikemol@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] How to prevent a dns amplification attack
Date: Thu, 28 Mar 2013 16:11:00
Message-Id: 51546B79.9060908@gmail.com
In Reply to: Re: [gentoo-user] How to prevent a dns amplification attack by Pandu Poluan
1 On 03/28/2013 12:06 PM, Pandu Poluan wrote:
2 >
3 > On Mar 28, 2013 10:38 PM, "Michael Mol" <mikemol@×××××.com
4 > <mailto:mikemol@×××××.com>> wrote:
5 >>
6 >> On 03/28/2013 04:51 AM, Norman Rieß wrote:
7 >> > Hello,
8 >> >
9 >> > i am using pdns recursor to provide a dns server which should be usable
10 >> > for everybody.The problem is, that the server seems to be used in dns
11 >> > amplification attacks.
12 >> > I googled around on how to prevent this but did not really find
13 >> > something usefull.
14 >> >
15 >> > Does anyone got an idea about this?
16 >>
17 >> I'm not sure it can be done. You can't make a resolver available to
18 >> "everybody" without somebody in that "everybody" group abusing it, and
19 >> that's exacly what happens in a DNS amplification attack.
20 >>
21 >> Restrict your resolver to be accessible only to your network or, at
22 >> most, those of the specific group of people you're seeking to help.
23 >>
24 >> You *might* try restricting the resolver to only respond to TCP requests
25 >> rather than UDP requests, but if the resolver sends response data along
26 >> with that first SYN+ACK, then nothing is solved, and you've opened
27 >> yourself up to a SYN flood-based DoS attack. (OTOH, if your resolver
28 >> went offline as a result of a SYN flood, at least it wouldn't be part of
29 >> an amplification attack any longer...)
30 >>
31 >
32 > Can't we rate limit UDP DNS request?
33 >
34 > E.g., limit each source IP to, let's say, 1 UDP per second?
35 >
36 > That should be doable easily using iptables.
37
38 That makes the resolver highly unreliable for normal use. Many sites
39 trigger resource grabs from 10-15 different domains. If all but the
40 first request is dropped due to rate limiting, you're going to have a
41 very, very broken experience.

Attachments

File name MIME type
signature.asc application/pgp-signature