diff options
author | 2022-09-06 17:20:36 +0200 | |
---|---|---|
committer | 2022-09-07 16:46:04 +0200 | |
commit | adda60cc2bb0fa46bed004070f29f90db96afbb3 (patch) | |
tree | 9efa77eccff0666b38dbb5cee926625f19ef5aa1 /include/net/act_api.h | |
parent | netfilter: nat: move repetitive nat port reserve loop to a helper (diff) | |
download | wireguard-linux-adda60cc2bb0fa46bed004070f29f90db96afbb3.tar.xz wireguard-linux-adda60cc2bb0fa46bed004070f29f90db96afbb3.zip |
netfilter: nat: avoid long-running port range loop
Looping a large port range takes too long. Instead select a random
offset within [ntohs(exp->saved_proto.tcp.port), 65535] and try 128
ports.
This is a rehash of an erlier patch to do the same, but generalized
to handle other helpers as well.
Link: https://patchwork.ozlabs.org/project/netfilter-devel/patch/20210920204439.13179-2-Cole.Dishington@alliedtelesis.co.nz/
Signed-off-by: Florian Westphal <fw@strlen.de>
Diffstat (limited to 'include/net/act_api.h')
0 files changed, 0 insertions, 0 deletions