linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Matt Corallo <netdev-list@mattcorallo.com>
To: Willy Tarreau <w@1wt.eu>, Keyu Man <kman001@ucr.edu>
Cc: Eric Dumazet <edumazet@google.com>,
	David Ahern <dsahern@gmail.com>, Florian Westphal <fw@strlen.de>,
	davem@davemloft.net, yoshfuji@linux-ipv6.org, dsahern@kernel.org,
	Jakub Kicinski <kuba@kernel.org>,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	Zhiyun Qian <zhiyunq@cs.ucr.edu>
Subject: Re: PROBLEM: DoS Attack on Fragment Cache
Date: Sat, 17 Apr 2021 21:30:07 -0400	[thread overview]
Message-ID: <c6467c1c-54f5-8681-6e7d-aa1d9fc2ff32@bluematt.me> (raw)
In-Reply-To: <20210417075030.GA14265@1wt.eu>

See-also "[PATCH] Reduce IP_FRAG_TIME fragment-reassembly timeout to 1s, from 30s" (and the two resends of it) - given 
the size of the default cache (4MB) and the time that it takes before we flush the cache (30 seconds) you only need 
about 1Mbps of fragments to hit this issue. While DoS attacks are concerning, its also incredibly practical (and I do) 
hit this issue in normal non-adversarial conditions.

Matt

On 4/17/21 03:50, Willy Tarreau wrote:
> On Sat, Apr 17, 2021 at 12:42:39AM -0700, Keyu Man wrote:
>> How about at least allow the existing queue to finish? Currently a tiny new
>> fragment would potentially invalid all previous fragments by letting them
>> timeout without allowing the fragments to come in to finish the assembly.
> 
> Because this is exactly the principle of how attacks are built: reserve
> resources claiming that you'll send everything so that others can't make
> use of the resources that are reserved to you. The best solution precisely
> is *not* to wait for anyone to finish, hence *not* to reserve valuable
> resources that are unusuable by others.
> 
> Willy
> 

  reply	other threads:[~2021-04-18  1:33 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <02917697-4CE2-4BBE-BF47-31F58BC89025@hxcore.ol>
2021-04-16 23:09 ` PROBLEM: DoS Attack on Fragment Cache Keyu Man
2021-04-17  0:31 ` David Ahern
2021-04-17  4:44   ` Eric Dumazet
2021-04-17  7:27     ` Willy Tarreau
     [not found]       ` <CAMqUL6bkp2Dy3AMFZeNLjE1f-sAwnuBWpXH_FSYTSh8=Ac3RKg@mail.gmail.com>
2021-04-17  7:50         ` Willy Tarreau
2021-04-18  1:30           ` Matt Corallo [this message]
2021-04-18  1:38             ` Keyu Man
2021-04-18  2:26               ` Matt Corallo
2021-04-18  4:39                 ` Willy Tarreau
2021-04-18 14:31                   ` Matt Corallo
2021-04-19  9:43                     ` Eric Dumazet
2021-04-19 17:20                       ` Matt Corallo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c6467c1c-54f5-8681-6e7d-aa1d9fc2ff32@bluematt.me \
    --to=netdev-list@mattcorallo.com \
    --cc=davem@davemloft.net \
    --cc=dsahern@gmail.com \
    --cc=dsahern@kernel.org \
    --cc=edumazet@google.com \
    --cc=fw@strlen.de \
    --cc=kman001@ucr.edu \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=w@1wt.eu \
    --cc=yoshfuji@linux-ipv6.org \
    --cc=zhiyunq@cs.ucr.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).