Fixed a bug that could crash the kernel, and limit the value of the sysctl variable: net.netfilter.nf_conntrack_tcp_no_window_check to 0 or 1. (#8967)

This commit is contained in:
unifreq 2022-03-01 00:29:49 +08:00 committed by GitHub
parent 7e7f062de9
commit 2d15f51c44
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -44,9 +44,11 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
+ [NF_SYSCTL_CT_PROTO_TCP_NO_WINDOW_CHECK] = {
+ .procname = "nf_conntrack_tcp_no_window_check",
+ .data = &init_net.ct.sysctl_no_window_check,
+ .maxlen = sizeof(unsigned int),
+ .maxlen = sizeof(u8),
+ .mode = 0644,
+ .proc_handler = proc_dointvec,
+ .proc_handler = proc_dou8vec_minmax,
+ .extra1 = SYSCTL_ZERO,
+ .extra2 = SYSCTL_ONE,
+ },
{}
};