山石网科Hillstone防火墙基础网络配置_CLI命令行(最新版)

1. 需求分析

部分用户需要在命令行界面下进行防火墙基础上网配置,本文展示如何在命令行下配置防火墙的基础上网步骤。

2. 解决方案

2.1 软硬件信息

硬件平台SG-6000-E1700

软件平台StoneOS 5.5R7P5

2.2 组网拓扑

2.3 环境说明

运营商线路连接防火墙外网出接口(E0/0)地址:200.0.0.135/24,内网接口(E0/1)地址:192.168.10.1/24连接PC,测试PC地址为192.168.10.10/32。

2.3 配置步骤

(1)外网接口配置

SG-6000(config)# interface e0/0

SG-6000(config-if-eth0/0)# zone untrust

SG-6000(config-if-eth0/0)# ip address 200.0.0.135

SG-6000(config-if-eth0/0)# manage ping

SG-6000(config-if-eth0/0)# manage ssh

SG-6000(config-if-eth0/0)# manage https

SG-6000(config-if-eth0/0)# exit

(2)内网接口配置

SG-6000(config)# interface e0/1

SG-6000(config-if-eth0/1)# zone trust

SG-6000(config-if-eth0/1)# ip address 192.168.10.1/24

SG-6000(config-if-eth0/1)# manage ping

SG-6000(config-if-eth0/1)# manage ssh

SG-6000(config-if-eth0/1)# manage https

SG-6000(config-if-eth0/1)# exit

(3)默认路由配置

SG-6000(config)# ip vrouter trust-vr

SG-6000(config-vrouter)# ip route0.0.0.0/0200.0.0.2(运营商提供的网关)

(4)源NAT配置

SG-6000(config-vrouter)# snatrule from any to any service any eif e0/0 trans-to eif-ip mode dynamicport

SG-6000(config-vrouter)# exit

(5)安全策略配置

SG-6000(config)# rule from any to any service any permit

注:本案例为全放行策略,具体业务环境请精细化策略。

2.4 结果验证

接口:

路由:

SNAT:

策略:

连通性测试:

2.5  注意事项

WebUI界面配置请参考《防火墙基础上网配置_WebUI》;

具体配置命令可参考《StoneOS命令行手册》。

更多防火墙等安全产品配置、FAQ等干货知识请见:https://kb.hillstonenet.com/cn/

你可能感兴趣的:(山石网科Hillstone防火墙基础网络配置_CLI命令行(最新版))