h3c交换机限制端口访问_勒索病毒,华为/H3C三层交换机/路由器用ACL访问控制实现端口禁用...

编程知识 更新时间:2023-05-02 04:42:08

前不久勒索病毒横行,很多人都纷纷中招,从公司到个人,损失相当惨重。有些公司在互联网入口上做了控制,但是这样并非完全,万一有人把中了毒的U盘插入网内设备上呢?那我们的内网中很有可能集体中招(打过相关补丁的除外)。

我们今天就说说如何在路由、交换机上实现相应的访问控制,封堵相关端口,防止病毒在网络内部蔓延。以华为和H3C设备配置为例。

什么?为什么没有思科?要啥自行车,我们需要支持国产!

**************************************

华为

#

acl number 3100 //创建ALC控制规则

rule 5 deny tcp destination-port eq 445 //禁止TCP 445端口数据

rule 10 deny tcp destination-port eq 135

rule 15 deny tcp destination-port eq 137

rule 20 deny tcp destination-port eq 138

rule 25 deny tcp destination-port eq 139

rule 30 deny udp destination-port eq 445

rule 35 deny udp destination-port eq 135

rule 40 deny udp destination-port eq 137

rule 45 deny udp destination-port eq 138

rule 50 deny udp destination-port eq 139

#

traffic classifier anti_wana operator or precedence 5 //创建流分类

if-match acl 3100 //将ACL与流分类关联

#

traffic behavior anti_wana //创建流行为

deny //动作为禁止

statistic enable //使能流量统计(可选)

#

traffic policy anti_wana match-order config //创建流策略

classifier anti_wana behavior anti_wana //将流分类和流行为进行关联

[全局视图]

traffic-policy anti_wana global inbound //全局应用入方向流策略

traffic-policy anti_wana global outbound //全局应用出方向流策略

[接口视图]         //也可以根据使用接口在接口上应用相关流策略

traffic-policy anti_wana inbound

traffic-policy anti_wana outbound

****************************************

H3C

大部分配置相同,毕竟本是同根生啊。

#

acl number 3100

rule 5 deny tcp destination-port eq 445

rule 10 deny tcp destination-port eq 135

rule 15 deny tcp destination-port eq 137

rule 20 deny tcp destination-port eq 138

rule 25 deny tcp destination-port eq 139

rule 30 deny udp destination-port eq 445

rule 35 deny udp destination-port eq 135

rule 40 deny udp destination-port eq 137

rule 45 deny udp destination-port eq 138

rule 50 deny udp destination-port eq 139

#

traffic classifier anti_wana operator and

if-match acl 3100

#

traffic behavior anti_wana

filter deny

#

qos policy anti_wana

classifier anti_wana behavior anti_wana

#

[接口视图]

qos apply policy anti_wana inbound

qos apply policy anti_wana outbound

[全局视图]         //基于全局应用QoS策略仅在MPE单板(仅入方向)和SPC单板上生效;部分设备无法使用此命令,只能在接口上应用。

qos apply policy anti_wana global inbound

qos apply policy anti_wana global outbound

==========================================

近期勒索病毒发生了变异,3389端口也在攻击之列中,请在ACL中添加相关规则,以防不测!

rule 55 deny udp destination-port eq 3389

rule 60 deny tcp destination-port eq 3389

更多推荐

h3c交换机限制端口访问_勒索病毒,华为/H3C三层交换机/路由器用ACL访问控制实现端口禁用...

本文发布于:2023-04-25 23:26:00,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/0aa2a091130dc287fb939e7c8f5ef9f3.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:交换机   端口   华为   路由   访问控制

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!

  • 103977文章数
  • 26196阅读数
  • 0评论数