Juniper防火墻配置
更新時間 2023-09-01 12:02:20
最近更新時間: 2023-09-01 12:02:20
分享文章
本文以Juniper防火墻為例介紹如何在本地站點中加載VPN配置。
使用IPsec VPN建立站點到站點的連接時,在配置完天翼云VPN網關后,您還需在本地站點的網關設備中進行VPN配置。
前提條件
- 已經在天翼云VPC內創建了IPsec連接。
- 已經下載了IPsec連接的配置。
IPsec協議信息
配置項 示例值 IKE
認證算法
SHA256
加密算法
3DES
DH分組
Group2
IKE版本
IKEv1
生命周期
86400
協商模式
main
PSK
aa123bb****
IPsec 認證算法
SHA256
加密算法
3DES
PFS
DH?group2
生命周期
3600
網絡配置信息
| 配置項 | 示例值 |
|---|---|
| VPC | 待和本地IDC互通的私網網段。 |
| VPN網關 | 天翼云VPN網關的公網IP地址。 |
| 本地IDC | 待和天翼云VPC互通的私網網段。 |
| 本地IDC | 本地網關設備的公網IP地址。 |
操作步驟
按照以下操作,在Juniper防火墻中加載用戶網關的配置。
- 登錄防火墻設備的命令行配置界面。
- 配置基本網絡、安全域和地址簿信息。
Set security zones security-zone trust address-book address net-cfgr_192-168-18-0--24 192.168.18.0/24
set security zones security-zone vpn address-book address net-cfgr_192-168-1-0--24 192.168.1.0/24
- 配置IKE策略。
set security ike policy ike-policy-cfgr mode main
set security ike policy ike-policy-cfgr pre-shared-key ascii-text "aa123bb****"
- 配置IKE網關、出接口和協議版本。
set security ike gateway ike-gate-cfgr ike-policy ike-policy-cfgr
set security ike gateway ike-gate-cfgr address 121.xxx.xxx.113
set security ike gateway ike-gate-cfgr external-interface ge-0/0/3
set security ike gateway ike-gate-cfgr version v1-only
- 配置IPsec策略。
set security ipsec policy ipsec-policy-cfgr proposal-set standard
- 應用IPsec策略。
set security ipsec vpn ipsec-vpn-cfgr ike gateway ike-gate-cfgr
set security ipsec vpn ipsec-vpn-cfgr ike ipsec-policy ipsec-policy-cfgr
set security ipsec vpn ipsec-vpn-cfgr bind-interface st0.0
set security ipsec vpn ipsec-vpn-cfgr establish-tunnels immediately
set security ipsec policy ipsec-policy-cfgr perfect-forward-secrecy keys group2
- 配置出站策略。
set security policies from-zone trust to-zone vpn policy trust-vpn-cfgr match source-address net-cfgr_192-168-18-0--24
set security policies from-zone trust to-zone vpn policy trust-vpn-cfgr match destination-address net-cfgr_192-168-1-0--24
set security policies from-zone trust to-zone vpn policy trust-vpn-cfgr match application any
set security policies from-zone trust to-zone vpn policy trust-vpn-cfgr then permit
- 配置入站策略。
set security policies from-zone vpn to-zone trust policy vpn-trust-cfgr match source-address net-cfgr_192-168-1-0--24
set security policies from-zone vpn to-zone trust policy vpn-trust-cfgr match destination-address net-cfgr_192-168-18-0--24
set security policies from-zone vpn to-zone trust policy vpn-trust-cfgr match application any
set security policies from-zone vpn to-zone trust policy vpn-trust-cfgr then permit