icmp: randomize the global rate limiter
authorEric Dumazet <edumazet@google.com>
Thu, 15 Oct 2020 18:42:00 +0000 (11:42 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 29 Oct 2020 08:05:32 +0000 (09:05 +0100)
commitdf838165a187b7c699ec372a2a136f9873112776
tree4f9a54fe4a8d6dcbd8493b5ef81647de2cb4e6d0
parent090178ce6f57e463b5db4b5f81f378d2ed837808
icmp: randomize the global rate limiter

[ Upstream commit b38e7819cae946e2edf869e604af1e65a5d241c5 ]

Keyu Man reported that the ICMP rate limiter could be used
by attackers to get useful signal. Details will be provided
in an upcoming academic publication.

Our solution is to add some noise, so that the attackers
no longer can get help from the predictable token bucket limiter.

Fixes: 4cdf507d5452 ("icmp: add a global rate limitation")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Reported-by: Keyu Man <kman001@ucr.edu>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Documentation/networking/ip-sysctl.txt
net/ipv4/icmp.c