netfilter: conntrack: limit sysctl setting for boolean options
Subsystems (2)
PATCH 1/1 netfilter: conntrack: limit sysctl setting for boolean options
From: Tonghao Zhang <[email protected]>
We use the zero and one to limit the boolean options setting. After this patch we only set 0 or 1 to boolean options for nf conntrack sysctl.
Signed-off-by Tonghao Zhang <[email protected]>
--- include/net/netns/conntrack.h | 6 ++--- net/netfilter/nf_conntrack_standalone.c | 48 ++++++++++++++++++++++----------- 2 files changed, 36 insertions(+), 18 deletions(-)
include/net/netns/conntrack.h +3 -3
@@ -24,9 +24,9 @@ struct nf_generic_net {struct nf_tcp_net {unsigned int timeouts[TCP_CONNTRACK_TIMEOUT_MAX ]; -unsigned int tcp_loose; -unsigned int tcp_be_liberal; -unsigned int tcp_max_retrans; +int tcp_loose; +int tcp_be_liberal; +int tcp_max_retrans; };enum udp_conntrack {
net/netfilter/nf_conntrack_standalone.c +33 -15
103 lines not on this page · raw message
Signature · 1 line
1.8.3.1
Quoted 5 lines · On Sun, Apr 07, 2019 at 08:14:20AM -0700, [email protected] wrote:
From: Tonghao Zhang <[email protected]>
We use the zero and one to limit the boolean options setting. After this patch we only set 0 or 1 to boolean options for nf conntrack sysctl.
Applied.