]> git.baikalelectronics.ru Git - kernel.git/commit
tcp: enable per-socket rate limiting of all 'challenge acks'
authorJason Baron <jbaron@akamai.com>
Thu, 14 Jul 2016 15:38:40 +0000 (11:38 -0400)
committerDavid S. Miller <davem@davemloft.net>
Fri, 15 Jul 2016 21:18:29 +0000 (14:18 -0700)
commit761ece095c4338a69b5f3c3a7d25409af17091b6
treed5540d3c373a2267191ed7bcfc9c43b2a917367b
parent1b0b93607679de8a5b5ca026aecee1bc1a3d017b
tcp: enable per-socket rate limiting of all 'challenge acks'

The per-socket rate limit for 'challenge acks' was introduced in the
context of limiting ack loops:

commit 2354123cb772 ("tcp: mitigate ACK loops for connections as tcp_sock")

And I think it can be extended to rate limit all 'challenge acks' on a
per-socket basis.

Since we have the global tcp_challenge_ack_limit, this patch allows for
tcp_challenge_ack_limit to be set to a large value and effectively rely on
the per-socket limit, or set tcp_challenge_ack_limit to a lower value and
still prevents a single connections from consuming the entire challenge ack
quota.

It further moves in the direction of eliminating the global limit at some
point, as Eric Dumazet has suggested. This a follow-up to:
Subject: tcp: make challenge acks less predictable

Cc: Eric Dumazet <edumazet@google.com>
Cc: David S. Miller <davem@davemloft.net>
Cc: Neal Cardwell <ncardwell@google.com>
Cc: Yuchung Cheng <ycheng@google.com>
Cc: Yue Cao <ycao009@ucr.edu>
Signed-off-by: Jason Baron <jbaron@akamai.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/tcp_input.c