小编Meh*_*hdi的帖子

/etc/sysctl.conf 中的 Linux 网络主机安全设置

在寻找更多保护 Linux 服务器的方法时,我发现了以下/etc/sysctl.conf配置。它就这样来了,没有太多解释。在生产环境(使用 Ubuntu 12.04 LTS)上使用它之前,我想知道它在 Web 服务器上的含义。

# Avoid a smurf attack
net.ipv4.icmp_echo_ignore_broadcasts = 1

# Turn on protection for bad icmp error messages
net.ipv4.icmp_ignore_bogus_error_responses = 1

# Turn on syncookies for SYN flood attack protection
net.ipv4.tcp_syncookies = 1

# Turn on and log spoofed, source routed, and redirect packets
net.ipv4.conf.all.log_martians = 1
net.ipv4.conf.default.log_martians = 1

# No source routed packets here
net.ipv4.conf.all.accept_source_route = 0
net.ipv4.conf.default.accept_source_route = 0

# Turn on reverse path filtering
net.ipv4.conf.all.rp_filter = 1 …
Run Code Online (Sandbox Code Playgroud)

security linux sysctl

2
推荐指数
1
解决办法
4239
查看次数

标签 统计

linux ×1

security ×1

sysctl ×1