防火牆接口類型
物理接口
1) 防火牆支持的接口可以是二層接口或者三層接口
2) 二層接口:portswitch
3) 三層接口:undo portswitch
邏輯接口
1) VT(virtual template)接口、dialer接口
2) tunnel接口、null接口
3) vlanif接口
4) 三層以太網子接口
5) Eth-Trunk接口、loobacp接口
防火牆的Eth-trunk
優點:
1) 本質是要提高鏈路的帶寬
2) 可靠性(LACP協議)
3) 負載分擔
Eth-trunk模式分類:
1) 手工負載分擔模式(默認)注意:所有鏈路都要參與轉發
2) 靜態LACP模式(沒有動態LACP)注意: 可以所有,也可以配置備份M:N形式
Eth-trunk接口類型
1) 三層Eth-trunk
2) 二層Eth-trunk
交換機上面爲二層Eth-trunk
第一步:新建Eth-trunk及模式
interface Eth-Trunk1
mode lacp-static ---------默認手工負載分擔
第二步:定義Eth-trunk類型
interface Eth-Trunk1
port link-type trunk
port trunk allow-pass vlan 2 to 4094
第三步:把接口加入Eth-trunk組
方法一
int XXXX
eth-trunk 1
方法二
int eth-trunk XX (防火牆不能)
trunkport g0/0/1 to 0/0/2
防火牆上面爲三層Eth-trunk
第一步:創建ETH-TRUNK及模式
interface Eth-Trunk1
mode lacp-static
第二步:接口成員加入ETH-TRUNK
int XXX
eth-trunk 1
檢查Eth-Trunk的配置
<FW1>display eth-trunk 1
15:10:49 2019/06/02
Eth-Trunk1's state information is:
Local:
LAG ID:1 WorkingMode: STATIC
Preempt Delay: Disable Hash Arichmetic: According to IP
System Priority: 32768 System ID: 2444-27ca-fbff
Least active-linknumber: 1 Max active-linknumber: 8
Operate Status: up Number of Up Port in Trunk: 2
----------------------------------------------------
ActorPortName Status PortType PortPri PortNo PortKey PortState Weigth
GigabitEthernet0/0/1 Selected 100M 32768 2 64 10111100 1
GigabitEthernet0/0/2 Selected 100M 32768 3 64 10111100 1
Partner:
----------------------------------------------------
ActorPortName SysPri SystemID PortPri PortNo PortKey PortState
GigabitEthernet0/0/1 32768 384c-4f60-9d20 32768 1 289 10111100 GigabitEthernet0/0/2 32768 384c-4f60-9d20 32768 2 289 10111100
防火牆的子接口
物理接口的子接口
防火牆配置子接口
interface GigabitEthernet1/0/1.10 -------先取子接口
vlan-type dot1q 10 ----------------------封裝VLAN ID
ip address 10.1.1.10 255.255.255.0
#
interface GigabitEthernet1/0/1.16
vlan-type dot1q 16
ip address 192.168.1.10 255.255.255.0
#
第二步:把子接口加ZONE
firewall zone trust
add interface GigabitEthernet1/0/1.10
#
firewall zone dmz
add interface GigabitEthernet1/0/1.16
檢查:
[FW1]display zone
20:26:16 2019/03/07
local
priority is 100
#
trust
priority is 85
interface of the zone is (2):
GigabitEthernet0/0/0
GigabitEthernet1/0/1.10
#
dmz
priority is 50
interface of the zone is (1):
GigabitEthernet1/0/1.16
第三步:測試防火牆直連通信
默認一個都通不了,因爲華爲防火牆默認ZONE與ZONE之間都沒有放行安全策略
默認的策略是deny
[FW1]display security-policy all
21:35:50 2019/09/05
Total:1
RULE ID RULE NAME STATE ACTION HITTED
-------------------------------------------------------------------------------
0 default enable deny 275
-------------------------------------------------------------------------------
[FW1]
security-policy
default action permit ----------默認全開安全策略
測試各個直接通信
測試完畢一定要記得關閉
security-policy
default action deny
注意:
關於PING的問題
如果在防火牆上PING各個ZONE,只要上面放行所有安全策略,就可以訪問
如果從各個安全區域訪問防火牆的接口,全放安全策略無用,必須開啓接口的訪問管理PING,這樣才能PING通防火牆接口
第五步:檢查測試
邏輯接口的子接口
三層eth-trunk可以配置IP
二層Eth-trunk鏈路類型
默認爲hybrid
interface Eth-Trunk1
port link-type trunk
port trunk allow-pass vlan 10 16 40 50
配置:
interface Eth-Trunk1.10
vlan-type dot1q 10
ip address 10.1.1.10 255.255.255.0
#
interface Eth-Trunk1.16
vlan-type dot1q 16
ip address 192.168.1.10 255.255.255.0
#
注意:
注意:所有防火牆的接口,無論是物理還是邏輯都需要加ZONE
防火牆所有的接口都定義ZONE
firewall zone trust
set priority 85
add interface Eth-Trunk1.10
#
firewall zone untrust
set priority 5
#
firewall zone dmz
set priority 50
add interface Eth-Trunk1.16
放行安全策略
security-policy
rule name trust_dmz
source-zone trust
destination-zone dmz
action permit
防火牆的vlanif接口
實驗演示防火牆上面的vlanif接口技術
配置思路:
第一步: 創建VLAN
vlan batch 20 30
第二步:把接口配置成爲二層
interface GigabitEthernet1/0/3
portswitch
port link-type access------------默認爲ACCESS,可以修改
port access vlan 20
#
interface GigabitEthernet1/0/4
portswitch
port link-type access
port access vlan 30
第三步:創建VLANIF接口
interface Vlanif20
ip address 10.1.2.10 255.255.255.0
service-manage ping permit
#
interface Vlanif30
ip address 10.1.3.10 255.255.255.0
service-manage ping permit
第四步:接口劃入ZONE
注意:不需要把接口再劃入ZONE,只需要邏輯加ZONE
firewall zone trust
add interface Vlanif20
add interface Vlanif30
第五步:測試檢查
注意:
同一個ZONE不需要配置安全策略,可以互相通信 ------結論對嗎?
現在USG6320 V100版本 ,就必須要配置同一個ZONE安全策略
security-policy
rule name trust_trust
source-zone trust
destination-zone trust
action permit