linux – 关闭/打开不可访问消息的原因?

我在这个问题( How can I stop Linux from sending ICMP “Destination Unreachable” responses?)上看到,有很多讨论指出你不应该关闭ICMP无法访问的消息.我想知道为什么以及何时应该?我也想知道怎么做.我知道它打破了MTU路径发现,但还有什么?

在cisco设备上你可以打开和关闭它,必须有一个原因.在他们的文档中,它只是说关闭它应该是为了提高安全性,因为它更难获取有关您的网络的信息?这就是cisco文档所说的内容.我需要实现在我公司的交换机上打开和关闭此功能的能力,以便我了解它.无论为什么我仍然必须这样做,但我想知道为什么要这样做或不给他人一个明智的答案.

当我想关闭ICMP重定向时,我这样做:

echo 0 > /proc/sys/net/ipv4/conf/all/accept_redirects

不可达的东西有类似的东西吗?

另一个线程上的用户这样做:

iptables -A OUTPUT -p icmp --icmp-type destination-unreachable -j DROP

这是一个好方法,然后我可以通过停止这种下降再次打开它?

我应该告诉别人他们不需要这个功能吗?

编辑:
在线我看到了这个:

An attacker could gather information’s about your network when scanning it,like unused IP’s and networks. When working with (interface-) Access-Lists,a deny statement triggers an ICMP Type 3     Code 9/10 message
(Network/Host is Administratively Prohibited). When disabling ICMP    unreachables 
on the interface where the ACL is applied,the deny statement 
acts like a ‘drop’ and does not reply.

解决方法

security.SE关于同一主题的非常详尽和精心编写的 answer,我强烈建议您阅读:

At its core ICMP was designed as the debugging,troubleshooting,and
error reporting mechanism for IP. This makes it insanely valuable so a
lot of thought needs to into shutting it down. It would be a bit like
tacking >/dev/null 2>&1 to the end of all your cron entries.

Source Quench / Redirect几乎已过时,已从现代网络设备中删除. IPv6要求ICMP完全运行.

底线:除非你完全理解其含义,否则不要阻止任何事情.如果我给你一个建议,那就是阻止你的外部防火墙中的icmp echo,并让其他所有内容保持打开状态.但这只是我的观点.

相关文章

/etc/sysctl.conf这个目录主要是配置一些系统信息,/etc/sys...
1.作用 useradd或adduser命令用来建立用户帐号和创建用户的起...
它们都是多模式编辑器,不同的是vim 是vi的升级版本,它不仅...
不管是我们在安装软件还是监测软件的使用性能,我们都要随时...
装好Tomcat7后,发现除了本机能访问外界访问不了,岂有此理。...
修改防火墙配置需要修改 /etc/sysconfig/iptables 这个文件,...