]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Implement a limit on on the number of IPv4 reassembly queues per bucket.
authorjtl <jtl@FreeBSD.org>
Tue, 14 Aug 2018 17:23:05 +0000 (17:23 +0000)
committerjtl <jtl@FreeBSD.org>
Tue, 14 Aug 2018 17:23:05 +0000 (17:23 +0000)
commitfba8297beef43c9019a985564ed57c99437f69eb
tree5d9536066171ffed471cc7a39307e98384f2cb3b
parent8568b90f96c96425332b2c8e74fd85756b425863
Implement a limit on on the number of IPv4 reassembly queues per bucket.

There is a hashing algorithm which should distribute IPv4 reassembly
queues across the available buckets in a relatively even way. However,
if there is a flaw in the hashing algorithm which allows a large number
of IPv4 fragment reassembly queues to end up in a single bucket, a per-
bucket limit could help mitigate the performance impact of this flaw.

Implement such a limit, with a default of twice the maximum number of
reassembly queues divided by the number of buckets. Recalculate the
limit any time the maximum number of reassembly queues changes.
However, allow the user to override the value using a sysctl
(net.inet.ip.maxfragbucketsize).

Reviewed by: jhb
Security: FreeBSD-SA-18:10.ip
Security: CVE-2018-6923
sys/netinet/ip_reass.c