2024-04-25 10:33:11 -04:00
|
|
|
net.ipv6.bindv6only = 1
|
|
|
|
|
2024-03-24 10:53:27 -04:00
|
|
|
net.ipv4.ip_local_port_range = 1024 65535
|
|
|
|
|
|
|
|
net.ipv4.conf.*.send_redirects = 0
|
|
|
|
net.ipv4.conf.*.accept_redirects = 0
|
|
|
|
net.ipv6.conf.*.accept_redirects = 0
|
|
|
|
|
|
|
|
# enforced with nftables to handle both IPv4 and IPv6 in the same way
|
|
|
|
net.ipv4.conf.default.rp_filter = 0
|
|
|
|
net.ipv4.conf.*.rp_filter = 0
|
|
|
|
|
2021-07-28 08:18:33 -04:00
|
|
|
net.ipv4.tcp_ecn = 1
|
|
|
|
net.ipv4.tcp_slow_start_after_idle = 0
|
2024-04-13 11:04:42 -04:00
|
|
|
net.ipv4.tcp_shrink_window = 1
|
2021-10-02 15:39:07 -04:00
|
|
|
net.ipv4.tcp_notsent_lowat = 131072
|
2021-07-28 08:18:33 -04:00
|
|
|
net.ipv4.tcp_fin_timeout = 30
|
|
|
|
net.ipv4.tcp_rfc1337 = 1
|
|
|
|
net.ipv4.tcp_tw_reuse = 1
|
|
|
|
|
2022-06-27 23:28:45 -04:00
|
|
|
# 31s with initial 1s RTO
|
|
|
|
net.ipv4.tcp_syn_retries = 4
|
2024-04-24 10:45:02 -04:00
|
|
|
net.netfilter.nf_conntrack_tcp_timeout_syn_sent = 31
|
2022-06-27 23:28:45 -04:00
|
|
|
|
|
|
|
# 15s with initial 1s RTO
|
|
|
|
net.ipv4.tcp_synack_retries = 3
|
2024-04-24 10:45:02 -04:00
|
|
|
net.netfilter.nf_conntrack_tcp_timeout_syn_recv = 15
|
2022-06-27 23:28:45 -04:00
|
|
|
|
|
|
|
# 102.2s with minimum 0.2s RTO
|
|
|
|
net.ipv4.tcp_retries2 = 8
|
|
|
|
|
|
|
|
# 25.4s with minimum 0.2s RTO
|
|
|
|
net.ipv4.tcp_orphan_retries = 6
|
|
|
|
|
2024-03-24 10:53:27 -04:00
|
|
|
net.mptcp.enabled = 0
|
2021-07-28 08:18:33 -04:00
|
|
|
|
2022-07-03 03:50:53 -04:00
|
|
|
net.netfilter.nf_conntrack_tcp_loose = 0
|
2022-07-03 05:28:54 -04:00
|
|
|
net.netfilter.nf_conntrack_tcp_timeout_established = 14400
|
2024-04-24 21:12:12 -04:00
|
|
|
net.netfilter.nf_conntrack_tcp_timeout_time_wait = 60
|
2024-04-30 12:13:02 -04:00
|
|
|
net.netfilter.nf_conntrack_udp_timeout = 15
|
|
|
|
net.netfilter.nf_conntrack_udp_timeout_stream = 15
|
2024-04-27 12:48:21 -04:00
|
|
|
net.netfilter.nf_conntrack_expect_max = 1
|
2022-07-03 03:50:53 -04:00
|
|
|
|
2021-07-28 08:18:33 -04:00
|
|
|
kernel.yama.ptrace_scope = 2
|
|
|
|
|
|
|
|
vm.mmap_rnd_bits = 32
|
|
|
|
vm.mmap_rnd_compat_bits = 16
|
|
|
|
|
|
|
|
kernel.kptr_restrict = 2
|
|
|
|
|
2021-09-07 22:50:57 -04:00
|
|
|
kernel.unprivileged_userns_clone = 0
|
|
|
|
|
2021-07-28 08:18:33 -04:00
|
|
|
kernel.unprivileged_bpf_disabled = 1
|
|
|
|
net.core.bpf_jit_harden = 2
|
|
|
|
|
2024-07-01 23:11:17 -04:00
|
|
|
kernel.io_uring_disabled = 1
|
|
|
|
kernel.io_uring_group = 2000
|
|
|
|
|
2021-07-28 08:18:33 -04:00
|
|
|
kernel.kexec_load_disabled = 1
|
|
|
|
|
|
|
|
fs.protected_regular = 2
|
|
|
|
fs.protected_fifos = 2
|
|
|
|
|
2023-01-09 14:18:30 -05:00
|
|
|
kernel.panic = -1
|
2021-07-28 08:18:33 -04:00
|
|
|
kernel.panic_on_oops = 1
|
|
|
|
|
|
|
|
dev.tty.ldisc_autoload = 0
|
2022-08-14 13:46:00 -04:00
|
|
|
|
|
|
|
fs.binfmt_misc.status = 0
|
2024-02-12 16:13:28 -05:00
|
|
|
|
|
|
|
kernel.sched_energy_aware = 0
|