H3C MSR系列路由器IPsec典型配置举例(V7)

H3C MSR系列路由器IPsec典型配置举例(V7)
H3C MSR系列路由器IPsec典型配置举例(V7)

1 简介

本文档介绍IPsec的典型配置举例。

2 配置前提

本文档适用于使用Comware V7软件版本的MSR系列路由器,如果使用过程中与产品实际情况有差异,请参考相关产品手册,或以设备实际情况为准。

本文档中的配置均是在实验室环境下进行的配置和验证,配置前设备的所有参数均采用出厂时的缺省配置。如果您已经对设备进行了配置,为了保证配置效果,请确认现有配置和以下举例中的配置不冲突。

本文档假设您已了解IPsec特性。

3 使用iNode客户端基于证书认证的L2TP over IPsec功能配置举例

3.1 组网需求

如图1所示,PPP用户Host与Device建立L2TP隧道,Windows server 2003作为CA服务器,要求:

?通过L2TP隧道访问Corporate network。

?用IPsec对L2TP隧道进行数据加密。

?采用RSA证书认证方式建立IPsec隧道。

图1 基于证书认证的L2TP over IPsec配置组网图

3.2 配置思路

由于使用证书认证方式建立IPsec隧道,所以需要在ike profile中配置local-identity 为dn,指定从本端证书中的主题字段取得本端身份。

3.3 使用版本

本举例是在R0106版本上进行配置和验证的。

3.4 配置步骤

3.4.1 Device的配置

(1) 配置各接口IP地址

# 配置接口GigabitEthernet2/0/1的IP地址。

system-view

[Device] interface gigabitethernet 2/0/1

[Device-GigabitEthernet2/0/1] ip address 192.168.100.50 24

[Device-GigabitEthernet2/0/1] quit

# 配置接口GigabitEthernet2/0/2的IP地址。

[Device] interface gigabitethernet 2/0/2

[Device-GigabitEthernet2/0/2] ip address 102.168.1.11 24

[Device-GigabitEthernet2/0/2] quit

# 配置接口GigabitEthernet2/0/3的IP地址。

[Device] interface gigabitethernet 2/0/3

[Device-GigabitEthernet2/0/3] ip address 192.168.1.1 24

[Device-GigabitEthernet2/0/3] quit

(2) 配置L2TP

# 创建本地PPP用户l2tpuser,设置密码为hello。

[Device] local-user l2tpuser class network

[Device-luser-network-l2tpuser] password simple hello

[Device-luser-network-l2tpuser] service-type ppp

[Device-luser-network-l2tpuser] quit

# 配置ISP域system对PPP用户采用本地验证。

[Device] domain system

[Device-isp-system] authentication ppp local

[Device-isp-system] quit

# 启用L2TP服务。

[Device] l2tp enable

# 创建接口Virtual-Template0,配置接口的IP地址为172.16.0.1/24。[Device] interface virtual-template 0

[Device-Virtual-Template0] ip address 172.16.0.1 255.255.255.0

# 配置PPP认证方式为PAP。

[Device-Virtual-Template0] ppp authentication-mode pap

# 配置为PPP用户分配的IP地址为172.16.0.2。

[Device-Virtual-Template0] remote address 172.16.0.2

[Device-Virtual-Template0] quit

# 创建LNS模式的L2TP组1。

[Device] l2tp-group 1 mode lns

# 配置LNS侧本端名称为lns。

[Device-l2tp1] tunnel name lns

# 关闭L2TP隧道验证功能。

[Device-l2tp1] undo tunnel authentication

# 指定接收呼叫的虚拟模板接口为VT0。

[Device-l2tp1] allow l2tp virtual-template 0

[Device-l2tp1] quit

(3) 配置PKI证书

# 配置PKI实体 security。

[Device] pki entity security

[Device-pki-entity-security] common-name device

[Device-pki-entity-security] quit

# 新建PKI域。

[Device] pki domain headgate

[Device-pki-domain-headgate] ca identifier LYQ

[Device-pki-domain-headgate] certificate request url http://192.168.1.51/certsrv/mscep/mscep.dll [Device-pki-domain-headgate] certificate request from ra

[Device-pki-domain-headgate] certificate request entity security

[Device-pki-domain-headgate] undo crl check enable

[Device-pki-domain-headgate] public-key rsa general name abc length 1024

[Device-pki-domain-headgate] quit

# 生成RSA算法的本地密钥对。

[Device] public-key local create rsa name abc

The range of public key modulus is (512 ~ 2048).

If the key modulus is greater than 512,it will take a few minutes. Press CTRL+C to abort.

Input the modulus length [default = 1024]:

Generating Keys...

..........................++++++

.++++++

Create the key pair successfully.

# 获取CA证书并下载至本地。

[Device] pki retrieve-certificate domain headgate ca

The trusted CA's finger print is:

MD5 fingerprint:8649 7A4B EAD5 42CF 5031 4C99 BFS3 2A99

SHA1 fingerprint:61A9 6034 181E 6502 12FA 5A5F BA12 0EA0 5187 031C

Is the finger print correct?(Y/N):y

Retrieved the certificates successfully.

# 手工申请本地证书。

[Device] pki request-certificate domain headgate

Start to request general certificate ...

Certificate requested successfully.

(4) 配置IPsec隧道

# 创建IKE安全提议。

[Device] ike proposal 1

[Device-ike-proposal-1] authentication-method rsa-signature

[Device-ike-proposal-1] encryption-algorithm 3des-cbc

[Device-ike-proposal-1] dh group2

[Device-ike-proposal-1] quit

# 配置IPsec安全提议。

[Device] ipsec transform-set tran1

[Device-ipsec-transform-set-tran1] esp authentication-algorithm sha1

[Device-ipsec-transform-set-tran1] esp encryption-algorithm 3des

[Device-ipsec-transform-set-tran1] quit

# 配置IKE profile。

[Device] ike profile profile1

[Device-ike-profile-profile1] local-identity dn

[Device-ike-profile-profile1] certificate domain headgate

[Device-ike-profile-profile1] proposal 1

[Device-ike-profile-profile1] match remote certificate device

[Device-ike-profile-profile1] quit

# 在采用数字签名认证时,指定总从本端证书中的主题字段取得本端身份。

[Device]ike signature-identity from-certificate

# 创建一条IPsec安全策略模板,名称为template1,序列号为1。

[Device] ipsec policy-template template1 1

[Device-ipsec-policy-template-template1-1] transform-set tran1

[Device-ipsec-policy-template-template1-1] ike-profile profile1

[Device-ipsec-policy-template-template1-1] quit

# 引用IPsec安全策略模板创建一条IPsec安全策略,名称为policy1,顺序号为1。

[Device] ipsec policy policy1 1 isakmp template template1

# 在接口上应用IPsec安全策略。

[Device] interface gigabitethernet 2/0/2

[Device-GigabitEthernet2/0/2] ipsec apply policy policy1

[Device-GigabitEthernet2/0/2] quit

3.4.2 Host的配置

(1) 从证书服务器上申请客户端证书

# 登录到证书服务器:http://192.168.1.51/certsrv ,点击“申请一个证书”。

图1 进入申请证书页面

# 点击“高级证书申请”。

图2 高级证书申请

# 选择第一项:创建并向此CA提交一个申请。

图3 创建并向CA提交一个申请

# 填写相关信息。

?需要的证书类型,选择“客户端身份验证证书”;

?密钥选项的配置,勾选“标记密钥为可导出”前的复选框。

# 点击<提交>,弹出一提示框:在对话框中选择“是”。

# 点击安装此证书。

图4 安装证书

(2) iNode客户端的配置(使用iNode版本为:iNode PC 5.2(E0409))

# 打开L2TP VPN连接,并单击“属性…(Y)”。

图5 打开L2TP连接

# 输入LNS服务器的地址,并启用IPsec安全协议,验证证方法选择证书认证。

图6 基本配置

# 单击<高级(C)>按钮,进入“L2TP设置”页签,设置L2TP参数如下图所示。图7 L2TP设置

# 单击“IPsec设置”页签,配置IPsec参数。图8 IPsec参数设置

# 单击“IKE设置”页签,配置IKE参数。

图9 IKE参数设置

# 单击“路由设置”页签,添加访问Corporate network的路由。图10 路由设置

# 完成上述配置后,单击<确定>按钮,回到L2TP连接页面。

3.5 验证配置

# 在L2TP连接对话框中,输入用户名“l2tpuser”和密码“hello”,单击<连接>按钮。

图11 连接L2TP

# 在弹出的对话框中选择申请好的证书,单击<确定>按钮。

图12 证书选择

# 通过下图可以看到L2TP连接成功。图13 连接成功

图14 连接成功

# 在Device上使用display ike sa命令,可以看到IPsec隧道第一阶段的SA正常建立。

display ike sa

Connection-ID Remote Flag DOI

------------------------------------------------------------------

10 102.168.1.1 RD IPSEC

Flags:

RD--READY RL--REPLACED FD-FADING

# 在Device上使用display ipsec sa命令可以看到IPsec SA的建立情况。

display ipsec sa

-------------------------------

Interface: GigabitEthernet2/0/2

-------------------------------

-----------------------------

IPsec policy: policy1

Sequence number: 1

Mode: template

-----------------------------

Tunnel id: 0

Encapsulation mode: tunnel

Perfect forward secrecy:

Path MTU: 1443

Tunnel:

local address: 102.168.1.11

remote address: 102.168.1.1

Flow:

sour addr: 102.168.1.11/255.255.255.255 port: 1701 protocol: udp

dest addr: 102.168.1.1/255.255.255.255 port: 0 protocol: udp

[Inbound ESP SAs]

SPI: 2187699078 (0x8265a386)

Transform set: ESP-ENCRYPT-3DES-CBC ESP-AUTH-SHA1

SA duration (kilobytes/sec): 1843200/3600

SA remaining duration (kilobytes/sec): 1843197/3294

Max received sequence-number: 51

Anti-replay check enable: Y

Anti-replay window size: 64

UDP encapsulation used for NAT traversal: N

Status: Active

[Outbound ESP SAs]

SPI: 3433374591 (0xcca5237f)

Transform set: ESP-ENCRYPT-3DES-CBC ESP-AUTH-SHA1

SA duration (kilobytes/sec): 1843200/3600

SA remaining duration (kilobytes/sec): 1843197/3294

Max sent sequence-number: 52

UDP encapsulation used for NAT traversal: N

Status: Active

3.6 配置文件

#

interface Virtual-Template0

ppp authentication-mode pap

remote address 172.16.0.2

ip address 172.16.0.1 255.255.255.0

#

interface GigabitEthernet2/0/1

ip address 192.168.100.50 255.255.255.0

#

interface GigabitEthernet2/0/2

ip address 102.168.1.11 255.255.255.0

ipsec apply policy policy1

#

interface GigabitEthernet2/0/3

ip address 192.168.1.1 255.255.255.0

#

domain system

authentication ppp local

#

local-user l2tpuser class network

password cipher $c$3$nl46fURLtkCkcbdnB6irTXma+E6u0c+h

service-type ppp

authorization-attribute user-role network-operator

#

pki domain headgate

ca identifier LYQ

certificate request url http://192.168.1.51/certsrv/mscep/mscep.dll

certificate request from ra

certificate request entity security

public-key rsa general name abc

undo crl check enable

#

pki entity security

common-name host

#

ipsec transform-set tran1

esp encryption-algorithm 3des-cbc

esp authentication-algorithm sha1

#

ipsec policy-template template1 1

transform-set tran1

ike-profile profile1

#

ipsec policy policy1 1 isakmp template template1

#

l2tp-group 1 mode lns

allow l2tp virtual-template 0

undo tunnel authentication

tunnel name lns

#

l2tp enable

#

ike signature-identity from-certificate

#

ike profile profile1

certificate domain headgate

local-identity dn

match remote certificate device

proposal 1

#

ike proposal 1

authentication-method rsa-signature

encryption-algorithm 3des-cbc

dh group2

#

4 IPsec over GRE的典型配置举例

4.1 组网需求

如图15所示,企业远程办公网络通过IPsec VPN接入企业总部,要求:通过GRE 隧道传输两网络之间的IPsec加密数据。

图15 IPsec over GRE组网图

4.2 配置思路

?为了对数据先进行IPsec处理,再进行GRE封装,访问控制列表需匹配数据的原始范围,并且要将IPsec应用到GRE隧道接口上。

?为了对网络间传输的数据先进行IPsec封装,再进行GRE封装,需要配置IPsec 隧道的对端IP地址为GRE隧道的接口地址。

4.3 使用版本

本举例是在R0106版本上进行配置和验证的。

4.4 配置步骤

4.4.1 Device A的配置

(1) 配置各接口IP地址

# 配置接口GigabitEthernet2/0/1的IP地址。

system-view

[DeviceA] interface gigabitethernet 2/0/1

[DeviceA-GigabitEthernet2/0/1] ip address 192.168.1.1 255.255.255.0

[DeviceA-GigabitEthernet2/0/1] tcp mss 1350

[DeviceA-GigabitEthernet2/0/1] quit

# 配置接口GigabitEthernet2/0/2的IP地址。

[DeviceA] interface gigabitethernet 2/0/2

[DeviceA-GigabitEthernet2/0/2] ip address 202.115.22.48 255.255.255.0

[DeviceA-GigabitEthernet2/0/2] quit

(2)配置GRE隧道

# 创建Tunnel0接口,并指定隧道模式为GRE over IPv4隧道。

[DeviceA] interface tunnel 0 mode gre

# 配置Tunnel0接口的IP地址为10.1.1.1/24。

[DeviceA-Tunnel0] ip address 10.1.1.1 255.255.255.0

# 配置Tunnel0接口的源端地址为202.115.22.48/24(Device A的GigabitEthernet2/0/2的IP地址)。

[DeviceA-Tunnel0] source 202.115.22.48

# 配置Tunnel0接口的目的端地址为202.115.24.50/24(Device B的GigabitEthernet2/0/2的IP地址)。

[DeviceA-Tunnel0] destination 202.115.24.50

[DeviceA-Tunnel0] quit

# 配置从Device A经过Tunnel0接口到Remote office network的静态路由。

[DeviceA] ip route-static 192.168.2.1 255.255.255.0 tunnel 0

(3)配置IPsec VPN

# 配置IKE keychain。

[DeviceA] ike keychain keychain1

[DeviceA-ike-keychain-keychain1] pre-shared-key address 10.1.1.2 255.255.255.0 key simple 123

[DeviceA-ike-keychain-keychain1] quit

# 创建ACL3000,定义需要IPsec保护的数据流。

[DeviceA] acl number 3000

[DeviceA-acl-adv-3000] rule 0 permit ip source 192.168.1.0 0.0.0.255 destination 192.168.2.0

0.0.0.255

[DeviceA-acl-adv-3000] quit

# 配置IPsec安全提议。

[DeviceA] ipsec transform-set tran1

[DeviceA-ipsec-transform-set-tran1] esp encryption-algorithm des

[DeviceA-ipsec-transform-set-tran1] esp authentication-algorithm sha1

[DeviceA-ipsec-transform-set-tran1] quit

# 创建一条IKE协商方式的IPsec安全策略,名称为policy1,序列号为1。

[DeviceA] ipsec policy policy1 1 isakmp

[DeviceA-ipsec-policy-isakmp-policy1-1] security acl 3000

[DeviceA-ipsec-policy-isakmp-policy1-1] remote-address 10.1.1.2

[DeviceA-ipsec-policy-isakmp-policy1-1] transform-set tran1

[DeviceA-ipsec-policy-isakmp-policy1-1] quit

# 在GRE隧道接口上应用安全策略。

[DeviceA] interface tunnel 0

[DeviceA-Tunnel0] ipsec apply policy policy1

[DeviceA-Tunnel0] quit

4.4.2 Device B的配置

(1) 配置各接口IP地址

# 配置接口GigabitEthernet2/0/1的IP地址。

system-view

[DeviceB] interface gigabitethernet 2/0/1

[DeviceB-GigabitEthernet2/0/1] ip address 192.168.2.1 255.255.255.0

[DeviceB-GigabitEthernet2/0/1] tcp mss 1350

[DeviceB-GigabitEthernet2/0/1] quit

# 配置接口GigabitEthernet2/0/2的IP地址。

[DeviceB] interface gigabitethernet 2/0/2

[DeviceB-GigabitEthernet2/0/2] ip address 202.115.24.50 255.255.255.0

[DeviceB-GigabitEthernet2/0/2] quit

(2)配置GRE隧道

# 创建Tunnel0接口,并指定隧道模式为GRE over IPv4隧道。

[DeviceB] interface tunnel 0 mode gre

# 配置Tunnel0接口的IP地址为10.1.1.2/24。

[DeviceB-Tunnel0] ip address 10.1.1.2 255.255.255.0

# 配置Tunnel0接口的源端地址为202.115.24.50/24(Device B的GigabitEthernet2/0/2的IP地址)。

[DeviceB-Tunnel0] source 202.115.24.50

# 配置Tunnel0接口的目的端地址为202.115.22.48/24(Device A的GigabitEthernet2/0/2的IP地址)。

[DeviceB-Tunnel0] destination 202.115.22.48

[DeviceB-Tunnel0] quit

# 配置从DeviceB经过Tunnel0接口到Corporate network的静态路由。

[DeviceB] ip route-static 192.168.1.1 255.255.255.0 tunnel 0

(3) 配置IPsec VPN

# 配置IKE keychain。

[DeviceB] ike keychain keychain1

[DeviceB-ike-keychain-keychain1] pre-shared-key address 10.1.1.1 255.255.255.0 key simple 123

[DeviceB-ike-keychain-keychain1] quit

# 创建ACL3000,定义需要IPsec保护的数据流。

[DeviceB] acl number 3000

[DeviceB-acl-adv-3000] rule 0 permit ip source 192.168.2.0 0.0.0.255 destination 192.168.1.0

0.0.0.255

[DeviceB-acl-adv-3000] quit

# 配置IPsec安全提议。

[DeviceB] ipsec transform-set tran1

[DeviceB-ipsec-transform-set-tran1] esp encryption-algorithm des

[DeviceB-ipsec-transform-set-tran1] esp authentication-algorithm sha1

[DeviceB-ipsec-transform-set-tran1] quit

# 创建一条IKE协商方式的IPsec安全策略,名称为policy1,序列号为1。

[DeviceB] ipsec policy policy1 1 isakmp

[DeviceB-ipsec-policy-isakmp-policy1-1] security acl 3000

[DeviceB-ipsec-policy-isakmp-policy1-1] remote-address 10.1.1.1

[DeviceB-ipsec-policy-isakmp-policy1-1] transform-set tran1

[DeviceB-ipsec-policy-isakmp-policy1-1] quit

# 在GRE隧道接口上应用安全策略。

[DeviceB] interface tunnel 0

[DeviceB-Tunnel0] ipsec apply policy policy1

[DeviceB-Tunnel0] quit

4.5 验证配置

# 以Corporate network的主机192.168.1.2向Remote office network的主机192.168.2.2发起通信为例,从192.168.1.2 ping 192.168.2.2,会触发IPsec协商,建立IPsec隧道,在成功建立IPsec隧道后,可以ping通。

C:\Users\corporatenetwork> ping 192.168.2.2

Pinging 192.168.2.2 with 32 bytes of data:

Request timed out.

Reply from 192.168.2.2: bytes=32 time=2ms TTL=254

Reply from 192.168.2.2: bytes=32 time=2ms TTL=254

Reply from 192.168.2.2: bytes=32 time=1ms TTL=254

Ping statistics for 192.168.2.2:

Packets: Sent = 4, Received = 3, Lost = 1 (25% loss),

Approximate round trip times in milli-seconds:

Minimum = 1ms, Maximum = 2ms, Average = 1ms

# 在Device A上使用display ike sa命令,可以看到第一阶段的SA正常建立。 display ike sa

Connection-ID Remote Flag DOI

------------------------------------------------------------------

1 10.1.1.

2 RD IPSEC

Flags:

RD--READY RL--REPLACED FD-FADING

# 在Device A上使用display ipsec sa命令可以看到IPsec SA的建立情况。 display ipsec sa

-------------------------------

Interface: Tunnel0

-------------------------------

-----------------------------

IPsec policy: policy1

Sequence number: 1

Mode: isakmp

-----------------------------

Tunnel id: 0

Encapsulation mode: tunnel

Perfect forward secrecy:

Path MTU: 1419

Tunnel:

local address: 10.1.1.1

remote address: 10.1.1.2

Flow:

sour addr: 192.168.1.1/255.255.255.255 port: 0 protocol: ip

dest addr: 192.168.2.1/255.255.255.255 port: 0 protocol: ip

[Inbound ESP SAs]

SPI: 3128557135 (0xba79fe4f)

Transform set: ESP-ENCRYPT-DES-CBC ESP-AUTH-SHA1

SA duration (kilobytes/sec): 1843200/3600

SA remaining duration (kilobytes/sec): 1843199/3550

Max received sequence-number: 3

Anti-replay check enable: Y

Anti-replay window size: 64

UDP encapsulation used for NAT traversal: N

Status: Active

[Outbound ESP SAs]

SPI: 2643166978 (0x9d8b8702)

Transform set: ESP-ENCRYPT-DES-CBC ESP-AUTH-SHA1

SA duration (kilobytes/sec): 1843200/3600

SA remaining duration (kilobytes/sec): 1843199/3550

Max sent sequence-number: 3

UDP encapsulation used for NAT traversal: N

Status: Active

# 在Device A上通过命令display interface tunnel 0可以查看经过GRE隧道传输的流量情况。

display interface tunnel 0

Tunnel0

Current state: UP

Line protocol state: UP

Description: Tunnel0 Interface

Bandwidth: 64kbps

Maximum Transmit Unit: 1476

Internet Address is 10.1.1.1/24 Primary

Tunnel source 202.115.22.48, destination 202.115.24.50

Tunnel keepalive disabled

Tunnel TTL 255

Tunnel protocol/transport GRE/IP

GRE key disabled

Checksumming of GRE packets disabled

Output queue - Urgent queuing: Size/Length/Discards 0/100/0

Output queue - Protocol queuing: Size/Length/Discards 0/500/0

Output queue - FIFO queuing: Size/Length/Discards 0/75/0

Last clearing of counters: Never

Last 300 seconds input rate: 0 bytes/sec, 0 bits/sec, 0 packets/sec

Last 300 seconds output rate: 0 bytes/sec, 0 bits/sec, 0 packets/sec

Input: 40 packets, 3300 bytes, 0 drops

Output: 41 packets, 3464 bytes, 0 drops

# 从Remote office network的主机向Corporate network的主机发起通信验证方法相同,此不赘述。

4.6 配置文件

Device A:

#

interface GigabitEthernet2/0/1

ip address 192.168.1.1 255.255.255.0

tcp mss 1350

#

interface GigabitEthernet2/0/2

ip address 202.115.22.48 255.255.255.0

#

interface Tunnel0 mode gre

ip address 10.1.1.1 255.255.255.0

source 202.115.22.48

destination 202.115.24.50

ipsec apply policy policy1

#

ip route-static 192.168.2.0 24 Tunnel0

#

acl number 3000

rule 0 permit ip source 192.168.1.0 0.0.0.255 destination 192.168.2.0 0.0.0.255 #

ipsec transform-set tran1

esp encryption-algorithm des-cbc

esp authentication-algorithm sha1

#

ipsec policy policy1 1 isakmp

transform-set tran1

security acl 3000

remote-address 10.1.1.2

#

ike keychain keychain1

pre-shared-key address 10.1.1.2 255.255.255.0 key cipher

$c$3$n6jdlYtuR+K6mijQ8qp4hMMjV/iteA==

#

Devoce B

#

interface GigabitEthernet2/0/1

ip address 192.168.2.1 255.255.255.0

tcp mss 1350

#

interface GigabitEthernet2/0/2

ip address 202.115.22.50 255.255.255.0

#

interface Tunnel0 mode gre

ip address 10.1.1.2 255.255.255.0

source 202.115.24.50

destination 202.115.22.48

ipsec apply policy policy1

#

ip route-static 192.168.1.1 24 Tunnel0

#

acl number 3000

rule 0 permit ip source 192.168.2.0 0.0.0.255 destination 192.168.1.0 0.0.0.255 #

ipsec transform-set tran1

esp encryption-algorithm des-cbc

esp authentication-algorithm sha1

CMSR系列路由器IPsec典型配置举例V

C M S R系列路由器I P s e c典型配置举例V 文件排版存档编号:[UYTR-OUPT28-KBNTL98-UYNN208]

1?简介 本文档介绍IPsec的典型配置举例。

2?配置前提 本文档适用于使用Comware V7软件版本的MSR系列路由器,如果使用过程中与产品实际情况有差异,请参考相关产品手册,或以设备实际情况为准。 本文档中的配置均是在实验室环境下进行的配置和验证,配置前设备的所有参数均采用出厂时的缺省配置。如果您已经对设备进行了配置,为了保证配置效果,请确认现有配置和以下举例中的配置不冲突。 本文档假设您已了解IPsec特性。 3?使用iNode客户端基于证书认证的L2TP over IPsec功能配置举例 3.1?组网需求 如所示,PPP用户Host与Device建立L2TP隧道,Windows server 2003作为CA服务器,要求: 通过L2TP隧道访问Corporate network。 用IPsec对L2TP隧道进行数据加密。 采用RSA证书认证方式建立IPsec隧道。 图1基于证书认证的L2TP over IPsec配置组网图 3.2?配置思路 由于使用证书认证方式建立IPsec隧道,所以需要在ike profile 中配置local-identity为dn,指定从本端证书中的主题字段取得 本端身份。 3.3?使用版本

本举例是在R0106版本上进行配置和验证的。 3.4?配置步骤 3.4.1?Device的配置 (1)配置各接口IP地址 #配置接口GigabitEthernet2/0/1的IP地址。 system-view [Device] interface gigabitethernet 2/0/1 [Device-GigabitEthernet2/0/1] quit #配置接口GigabitEthernet2/0/2的IP地址。 [Device] interface gigabitethernet 2/0/2 [Device-GigabitEthernet2/0/2] quit #配置接口GigabitEthernet2/0/3的IP地址。 [Device] interface gigabitethernet 2/0/3 [Device-GigabitEthernet2/0/3] quit (2)配置L2TP #创建本地PPP用户l2tpuser,设置密码为hello。 [Device] local-user l2tpuser class network [Device-luser-network-l2tpuser] password simple hello [Device-luser-network-l2tpuser] service-type ppp [Device-luser-network-l2tpuser] quit #配置ISP域system对PPP用户采用本地验证。 [Device] domain system

H3C IRF堆叠典型配置举例

典型配置举例一IRF检测方式)1.1.1 IRF典型配置举例(LACP MAD 1. 组网需求现的接入需求。由于公司人员激增,接入层交换机提供的端口 数目已经不能满足PC 需要在保护现有投资的基础上扩展端口接入数量,并要求网络易管理、易维护。组网图2. 典型配置组网图(LACP MAD1-13 IRF检测方式)图 3. 配置思路 Device A提供的接入端口数目已经不能满足网络需求,需要另外增加一台设备?Device B。(本文以两台设备组成IRF为例,在实际组网中可以根据需要,将多台设备组成IRF,配置思路和配置步骤与本例类似) 鉴于第二代智能弹性架构IRF技术具有管理简便、网络扩展能力强、可靠性高等?优点,所以本例使用IRF技术构建接入层(即在Device A和Device B上配置IRF功能)。 为了防止万一IRF链路故障导致IRF分裂、网络中存在两个配置冲突的IRF,需?要启用MAD 检测功能。因为接入层设备较多,我们采用LACP MAD检测。 4. 配置步骤 为便于区分,下文配置中假设IRF形成前Device A的系统名称为DeviceA,Device B的系统名称为Device B;中间设备Device C的系统名称为DeviceC。 (1)配置设备编号 # Device A保留缺省编号为1,不需要进行配置。 。2上将设备的成员编号修改为Device B在# system-view [DeviceB] irf member 1 renumber 2 Warning: Renumbering the switch number may result in configuration change or loss. Continue? [Y/N]:y [DeviceB]

H3C S5600系列交换机典型配置举例

S5600系列交换机典型配置举例 2.1.1 静态路由典型配置 1. 组网需求 (1)需求分析 某小型公司办公网络需要任意两个节点之间能够互通,网络结构简单、稳定, 用户希望最大限度利用现有设备。用户现在拥有的设备不支持动态路由协议。 根据用户需求及用户网络环境,选择静态路由实现用户网络之间互通。 (2)网络规划 根据用户需求,设计如图2-1所示网络拓扑图。 图2-1 静态路由配置举例组网图 2. 配置步骤 交换机上的配置步骤: # 设置以太网交换机Switch A的静态路由。 system-view [SwitchA] ip route-static 1.1.3.0 255.255.255.0 1.1.2.2 [SwitchA] ip route-static 1.1.4.0 255.255.255.0 1.1.2.2 [SwitchA] ip route-static 1.1.5.0 255.255.255.0 1.1.2.2 # 设置以太网交换机Switch B的静态路由。 system-view [SwitchB] ip route-static 1.1.2.0 255.255.255.0 1.1.3.1 [SwitchB] ip route-static 1.1.5.0 255.255.255.0 1.1.3.1

[SwitchB] ip route-static 1.1.1.0 255.255.255.0 1.1.3.1 # 设置以太网交换机Switch C的静态路由。 system-view [SwitchC] ip route-static 1.1.1.0 255.255.255.0 1.1.2.1 [SwitchC] ip route-static 1.1.4.0 255.255.255.0 1.1.3.2 主机上的配置步骤: # 在主机A上配缺省网关为1.1.5.1,具体配置略。 # 在主机B上配缺省网关为1.1.4.1,具体配置略。 # 在主机C上配缺省网关为1.1.1.1,具体配置略。 至此图中所有主机或以太网交换机之间均能两两互通。 2.1.2 RIP典型配置 1. 组网需求 (1)需求分析 某小型公司办公网络需要任意两个节点之间能够互通,网络规模比较小。需要 设备自动适应网络拓扑变化,降低人工维护工作量。 根据用户需求及用户网络环境,选择RIP路由协议实现用户网络之间互通。(2)网络规划 根据用户需求,设计如图2-2所示网络拓扑图。 设备接口IP地址设备接口IP地址 Switch A Vlan-int1110.11.2.1/24Switch B Vlan-int1110.11.2.2/24 Vlan-int2155.10.1.1/24Vlan-int3196.38.165.1/24 Switch C Vlan-int1110.11.2.3/24 Vlan-int4117.102.0.1/16 图2-2 RIP典型配置组网图 2. 配置步骤

H3C MSR系列路由器IPsec典型配置举例(V7)

1 简介 本文档介绍IPsec的典型配置举例。 2 配置前提 本文档适用于使用Comware V7软件版本的MSR系列路由器,如果使用过程中与产品实际情况有差异,请参考相关产品手册,或以设备实际情况为准。 本文档中的配置均是在实验室环境下进行的配置和验证,配置前设备的所有参数均采用出厂时的缺省配置。如果您已经对设备进行了配置,为了保证配置效果,请确认现有配置和以下举例中的配置不冲突。 本文档假设您已了解IPsec特性。 3 使用iNode客户端基于证书认证的L2TP over IPsec功能配置举例 3.1 组网需求 如图1所示,PPP用户Host与Device建立L2TP隧道,Windows server 2003作为CA服务器,要求: ?通过L2TP隧道访问Corporate network。 ?用IPsec对L2TP隧道进行数据加密。 ?采用RSA证书认证方式建立IPsec隧道。 图1 基于证书认证的L2TP over IPsec配置组网图 3.2 配置思路 由于使用证书认证方式建立IPsec隧道,所以需要在ike profile中配置local-identity 为dn,指定从本端证书中的主题字段取得本端身份。 3.3 使用版本 本举例是在R0106版本上进行配置和验证的。 3.4 配置步骤 3.4.1 Device的配置 (1) 配置各接口IP地址

# 配置接口GigabitEthernet2/0/1的IP地址。 system-view [Device] interface gigabitethernet 2/0/1 [Device-GigabitEthernet2/0/1] ip address 192.168.100.50 24 [Device-GigabitEthernet2/0/1] quit # 配置接口GigabitEthernet2/0/2的IP地址。 [Device] interface gigabitethernet 2/0/2 [Device-GigabitEthernet2/0/2] ip address 102.168.1.11 24 [Device-GigabitEthernet2/0/2] quit # 配置接口GigabitEthernet2/0/3的IP地址。 [Device] interface gigabitethernet 2/0/3 [Device-GigabitEthernet2/0/3] ip address 192.168.1.1 24 [Device-GigabitEthernet2/0/3] quit (2) 配置L2TP # 创建本地PPP用户l2tpuser,设置密码为hello。 [Device] local-user l2tpuser class network [Device-luser-network-l2tpuser] password simple hello [Device-luser-network-l2tpuser] service-type ppp [Device-luser-network-l2tpuser] quit # 配置ISP域system对PPP用户采用本地验证。 [Device] domain system [Device-isp-system] authentication ppp local [Device-isp-system] quit # 启用L2TP服务。 [Device] l2tp enable # 创建接口Virtual-Template0,配置接口的IP地址为172.16.0.1/24。[Device] interface virtual-template 0 [Device-Virtual-Template0] ip address 172.16.0.1 255.255.255.0 # 配置PPP认证方式为PAP。 [Device-Virtual-Template0] ppp authentication-mode pap # 配置为PPP用户分配的IP地址为172.16.0.2。 [Device-Virtual-Template0] remote address 172.16.0.2 [Device-Virtual-Template0] quit # 创建LNS模式的L2TP组1。 [Device] l2tp-group 1 mode lns # 配置LNS侧本端名称为lns。 [Device-l2tp1] tunnel name lns # 关闭L2TP隧道验证功能。 [Device-l2tp1] undo tunnel authentication # 指定接收呼叫的虚拟模板接口为VT0。 [Device-l2tp1] allow l2tp virtual-template 0 [Device-l2tp1] quit (3) 配置PKI证书 # 配置PKI实体 security。

H3C路由器配置实例

通过在外网口配置nat基本就OK了,以下配置假设Ethernet0/0为局域网接口,Ethernet0/1为外网口。 1、配置内网接口(E t h e r n e t0/0):[M S R20-20]i n t e r f a c e E t h e r n e t0/0 [M S R20-20 2、使用动态分配地址的方式为局域网中的P C分配地址[M S R20-20]d h c p s e r v e r i p-p o o l 1 [M S R20-20-d h c p-p o o l-1]n e t w o r k2 4 [M S R20-20 [M S R20-20 3、配置n a t [M S R20-20]n a t a d d r e s s-g r o u p1公网I P公网I P [MSR20-20]acl number 3000 [MSR20-20-acl-adv-3000]rule 0 permit ip 4、配置外网接口(Ethernet0/1) [MSR20-20] interface Ethernet0/1 [MSR20-20- Ethernet0/1]ip add 公网IP [MSR20-20- Ethernet0/1] nat outbound 3000 address-group 1 5.加默缺省路由 [MSR20-20]route-stac 0.0.0外网网关 总结: 在2020路由器下面, 配置外网口, 配置内网口, 配置acl 作nat, 一条默认路由指向电信网关. ok! Console登陆认证功能的配置 关键词:MSR;console; 一、组网需求: 要求用户从console登录时输入已配置的用户名h3c和对应的口令h3c,用户名和口令正确才能登录成功。 二、组网图: 三、配置步骤:

H3C SecPath系列防火墙典型配置案例集-6W100-SecPath系列防火墙IPSec典型配置举例

SecPath系列防火墙IPSec典型配置举例 关键词:IKE、IPSec 摘要:本章首先介绍了IKE和IPSec的基本概念,随后说明了防火墙的配置方法,最后给出两种典型应用的举例。 缩略语: 缩略语英文全名中文解释 IKE Internet Key Exchange 因特网密钥交换 Security IP网络安全协议 IPsec IP

目录 1 特性简介 (3) 1.1 IPSec基本概念 (3) 1.1.1 SA (3) 1.1.2 封装模式 (3) 2 应用场合 (4) 3 配置指南 (4) 3.1 配置概述 (4) 3.2 配置ACL (6) 3.3 配置IKE (6) 3.3.1 配置IKE全局参数 (6) 3.3.2 配置IKE安全提议 (7) 3.3.3 配置IKE对等体 (8) 3.4 IPSec安全提议 (10) 3.5 配置安全策略模板 (12) 3.6 配置安全策略 (14) 3.7 应用安全策略组 (16) 4 配置举例一:基本应用 (17) 4.1 组网需求 (17) 4.2 使用版本 (18) 4.3 配置步骤 (18) 4.4 配置结果验证 (27) 4.4.1 查看IPSec安全联盟 (27) 4.4.2 查看报文统计 (27) 5 配置举例二:与NAT结合 (27) 5.1 组网需求 (27) 5.2 配置说明 (28) 5.3 配置步骤 (28) 5.4 配置验证结果 (34) 5.4.1 查看IPSec安全联盟 (34) 5.4.2 查看报文统计 (35) 6 注意事项 (35) 7 相关资料 (35) 7.1 相关协议和标准 (35) 7.2 其它相关资料 (36)

史上最详细H3C路由器NAT典型配置案例

H3C路由器NAT典型配置案列(史上最详细)神马CCIE,H3CIE,HCIE等网络工程师日常实施运维必备,你懂的。 NAT典型配置举例 内网用户通过NAT地址访问外网(静态地址转换) 1. 组网需求 内部网络用户使用外网地址访问Internet。 2. 组网图 图1-5 静态地址转换典型配置组网图 3. 配置步骤 # 按照组网图配置各接口的IP地址,具体配置过程略。 # 配置内网IP地址到外网地址之间的一对一静态地址转换映射。 system-view [Router] nat static outbound 使配置的静态地址转换在接口GigabitEthernet1/2上生效。 [Router] interface gigabitethernet 1/2 [Router-GigabitEthernet1/2] nat static enable [Router-GigabitEthernet1/2] quit 4. 验证配置 # 以上配置完成后,内网主机可以访问外网服务器。通过查看如下显示信息,可以验证以上配置成功。 [Router] display nat static Static NAT mappings:

There are 1 outbound static NAT mappings. IP-to-IP: Local IP : Global IP : Interfaces enabled with static NAT: There are 1 interfaces enabled with static NAT. Interface: GigabitEthernet1/2 # 通过以下显示命令,可以看到Host访问某外网服务器时生成NAT会话信息。[Router] display nat session verbose Initiator: Source IP/port: Destination IP/port: VPN instance/VLAN ID/VLL ID: -/-/- Protocol: ICMP(1) Responder: Source IP/port: Destination IP/port: VPN instance/VLAN ID/VLL ID: -/-/- Protocol: ICMP(1) State: ICMP_REPLY Application: INVALID Start time: 2012-08-16 09:30:49 TTL: 27s Interface(in) : GigabitEthernet1/1 Interface(out): GigabitEthernet1/2 Initiator->Responder: 5 packets 420 bytes Responder->Initiator: 5 packets 420 bytes Total sessions found: 1 内网用户通过NAT地址访问外网(地址不重叠) 1. 组网需求

史上最详细H3C路由器NAT典型配置案例

神马CCIE, H3CIE,HCIE等网络工程师日常实施运维必备,你懂的。 NAT典型配置举例 内网用户通过NAT地址访问外网(静态地址转换) 1. 组网需求 内部网络用户使用外网地址访问In ternet 。 2. 组网图 图1-5 静态地址转换典型配置组网图 3. 配置步骤 # 按照组网图配置各接口的IP地址,具体配置过程略。 # 配置内网IP地址到外网地址之间的一对一静态地址转换映射。 system-view [Router] nat static outbou nd 使配置的静态地址转换在接口GigabitEthernet1/2 生效。 [Router] in terface gigabitether net 1/2 [Router-GigabitEthernet1/2] nat static en able [Router-GigabitEthernet1/2] quit 4. 验证配置 #以上配置完成后,内网主机可以访问外网服务器。通过查看如下显示信息,可以验证以 上配置成功。 [Router] display nat static Static NAT mapp in gs: There are 1 outbo und static NAT mapp in gs. IP-to-IP: Local IP : Global IP : In terfaces en abled with static NAT:

There are 1 in terfaces en abled with static NAT.

In terface: GigabitEthernet1/2 Total sessi ons found: 1 内网用户通过 NAT 地址访问外网(地址不重叠) 1. 组网需求 ? 某公司内网使用的IP 地址为。 ? 该公司拥有和两个外网 IP 地址。 需要实现,内部网络中网段的用户可以访问 In ternet ,其它网段的用户不能访问 In ternet 使用的外网地址为和。 2. 组网图 #通过以下显示命令,可以看到 [Router] display nat sessi on verbose In itiator: Source IP/port: ID: -/-/ Protocol: ICMP(1) Resp on der: Source IP/port: ID: -/-/ Protocol: ICMP(1) State: ICMP_REPLY Applicatio n: INVALID Start time: 2012-08-16 09:30:49 Interface(in): GigabitEthernet1/1 In terface(out): GigabitEthernet1/2 In itiator->Resp on der: Resp on der- >ln itiator: Host 访问某外网服务器时生成 Desti nati on IP/port: Desti nati on IP/port: TTL: 27s 5 packets 5 packets NAT 会话信息。 VPN in sta nce/VLAN ID/VLL VPN in sta nce/VLAN ID/VLL 420 bytes 420 bytes

H3C路由器设置

H3C路由器设置 1. 端口映射 如某公司内网有做游戏或者其他服务机器,需要外网的机器访问时,需要设置端口映射 内部机器:192.168.2.223 外网IP:61.190.38.198 需要做端口映射:在NAT配置中设置 2. 内网中的PC通过域名访问内部的服务器 内部服务器IP:192.168.3.2(VLAN3) TCP端口:80和3777 内部PC机:192.168.2.0/24和192.168.1.0/24(VLAN2和VLN1) 命令配置: Acl number 3400 Rule 0 permit tcp source 192.168.2.0 0.0.0.255 destination 192.168.3.2 0 destination-port eg 80 Rule 5 permit tcp source 192.168.2.0 0.0.0.255 destination 192.168.3.2 0 destination-port eg 3777

Rule 10 permit tcp source 192.168.1.0 0.0.0.255 destination 192.168.3.2 0 destination-port eg 80 Rule 15 permit tcp source 192.168.1.0 0.0.0.255 destination 192.168.3.2 0 destination-port eg 3777 Interface vlan-interface 3 Nat outbound 3400 注:acl的子网掩码和子网掩码是相反的,192.168.1.0/24的子网掩码是255.255.255.0 则acl的子网掩码是0.0.0.255 3. IP和MAC地址绑定 防止ARP欺骗 1) arp扫描:ARP防攻击 2) 固化 4. 互联网访问控制 1) 设置时间

H3C IPv6 静态路由配置

操作手册 IP路由分册 IPv6 静态路由目录 目录 第1章 IPv6静态路由配置......................................................................................................1-1 1.1 IPv6静态路由简介.............................................................................................................1-1 1.1.1 IPv6静态路由属性及功能........................................................................................1-1 1.1.2 IPv6缺省路由..........................................................................................................1-1 1.2 配置IPv6静态路由.............................................................................................................1-2 1.2.1 配置准备..................................................................................................................1-2 1.2.2 配置IPv6静态路由...................................................................................................1-2 1.3 IPv6静态路由显示和维护..................................................................................................1-2 1.4 IPv6静态路由典型配置举例(路由应用).........................................................................1-3 1.5 IPv6静态路由典型配置举例(交换应用).........................................................................1-5

IPSec配置案例

防火墙产品典型组网配置指导及使用注意事项 ike sa keepalive-timer interval 30 ike sa keepalive-timer timeout 90 1 IPSEC 建立点到点SA 配置采用IKE 方式建立SA, IKE自动协商方式相对比较简单,只需要配置好IKE协商安全策略的信息,由IKE自动协商来创建和维护安全联盟。当与Eudemon 进行通信的对等体设备数量较少时,或是在小型静态环境中,手工配置安全联盟是可行的,但不推荐。对于小、中、大型的动态网络环境中,我们都推荐使用IKE协商建立安全联盟。第一节介绍点到点网络结构,使用IKE建立SA的典型配置 1.1 组网图 图1IKE点到点网络典型组网图 1.2 组网需求 ●PC1与PC2之间进行安全通信,在FWA与FWB之间使用IKE自动协 商建立安全通道。 ●在FWA和FWB上均配置序列号为10的IKE提议。 ●为使用pre-shared key验证方法的提议配置验证字。 ●FWA与FWB均为固定公网地址 1.3 适用产品、版本 设备型号:Eudemon100/100S/200/200S, Eudemon300/500/1000, USG50/3000/5000 实验设备: FWA Eudemon500 FWB Eudemon200

软件版本:V2R1及以上实验版本Eudemon500 V200R006C02B059 Eudemon200 V200R001B01D036 1.4 配置思路和步骤 1)防火墙基本配置,包括IP地址,安全域 2)配置公网路由, 一般情况下,防火墙上配置静态路由 3)定义用于包过滤和加密的数据流 4) 域间通信规则 5)配置IPSec安全提议 6) 配置IKE提议 7) 配置IKE Peer 8) 配置安全策略 9) 引用安全策略 1.5 配置过程和解释(关键配置) 配置FWA: 1)配置到达PC2的静态路由 [FWA]ip route-static 0.0.0.0 0.0.0.0 200.0.0.2 2)定义用于包过滤和加密的数据流 [FWA]acl 3000 [FWA-acl-adv-3000]rule permit ip source 10.0.0.0 0.0.0.255 destination 10.0.1.0 0.0.0.255 [FWA-acl-adv-3000]quit [FWA]acl 3001 [FWA-acl-adv-3001]rule permit ip source 10.0.1.0 0.0.0.255 [FWA-acl-adv-3001]quit 3)配置trust与untrust域间包过滤规则 [FWA]firewall interzone trust untrust [FWA-interzone-trust-untrust]packet-filter 3000 outbound [FWA-interzone-trust-untrust]packet-filter 3001 inbound

[史上完整]H3C路由器NAT典型配置案例解析

H3C路由器NAT典型配置案列(史上最详细) 神马CCIE,H3CIE,HCIE等网络工程师日常实施运维必备,你懂的。 1.11 NAT典型配置举例 1.11.1 内网用户通过NAT地址访问外网(静态地址转换) 1. 组网需求 内部网络用户10.110.10.8/24使用外网地址202.38.1.100访问Internet。 2. 组网图 图1-5 静态地址转换典型配置组网图 3. 配置步骤 # 按照组网图配置各接口的IP地址,具体配置过程略。 # 配置内网IP地址10.110.10.8到外网地址202.38.1.100之间的一对一静态地址转换映射。 system-view [Router] nat static outbound 10.110.10.8 202.38.1.100 # 使配置的静态地址转换在接口GigabitEthernet1/2上生效。 [Router] interface gigabitethernet 1/2 [Router-GigabitEthernet1/2] nat static enable [Router-GigabitEthernet1/2] quit 4. 验证配置 # 以上配置完成后,内网主机可以访问外网服务器。通过查看如下显示信息,可以验证以上配置成功。 [Router] display nat static Static NAT mappings: There are 1 outbound static NAT mappings. IP-to-IP: Local IP : 10.110.10.8 Global IP : 202.38.1.100 Interfaces enabled with static NAT: There are 1 interfaces enabled with static NAT. Interface: GigabitEthernet1/2 # 通过以下显示命令,可以看到Host访问某外网服务器时生成NAT会话信息。 [Router] display nat session verbose Initiator: Source IP/port: 10.110.10.8/42496 Destination IP/port: 202.38.1.111/2048 VPN instance/VLAN ID/VLL ID: -/-/-

路由器-GRE-Over-IPSec典型配置

路由器-GRE-Over-IPSec典型配置 【需求】 分部1和分部2通过野蛮IPSec的方式连接到中心,采用GRE-Over-IPSec的方式,在tunnel上运行OSPF协议来实现总部和分部之间的互通。 【组网图】

【验证】 1、中心上的ike sa 状态: disp ike sa connection-id peer flag phase doi ---------------------------------------------------------- 4 202.101.3.2 RD 1 IPSEC 5 202.101.3.2 RD 2 IPSEC 2 202.101.2.2 RD 1 IPSEC 3 202.101.2.2 RD 2 IPSEC flag meaning RD--READY ST--STAYALIVE RL--REPLACED FD--FADING TO—TIMEOUT 2、中心上的IPSec sa状态:

disp ipsec sa =============================== Interface: Serial2/0/0 path MTU: 1500 =============================== ----------------------------- IPsec policy name: "center" sequence number: 10 mode: isakmp ----------------------------- connection id: 3 encapsulation mode: tunnel perfect forward secrecy: None tunnel: local address: 202.101.1.2 remote address: 202.101.2.2 flow: (72 times matched) sour addr: 202.101.1.2/255.255.255.255 port: 0 protocol: GRE dest addr: 202.101.2.2/255.255.255.255 port: 0 protocol: GRE [inbound ESP SAs] spi: 1168206412 (0x45a16a4c) proposal: ESP-ENCRYPT-DES ESP-AUTH-MD5 sa remaining key duration (bytes/sec): 1887434028/3365 max received sequence-number: 33 udp encapsulation used for nat traversal: N [outbound ESP SAs] spi: 2150942891 (0x8034c8ab) proposal: ESP-ENCRYPT-DES ESP-AUTH-MD5 sa remaining key duration (bytes/sec): 1887433260/3365 max sent sequence-number: 36 udp encapsulation used for nat traversal: N ----------------------------- IPsec policy name: "center" sequence number: 20 mode: isakmp ----------------------------- connection id: 4 encapsulation mode: tunnel perfect forward secrecy: None tunnel: local address: 202.101.1.2 remote address: 202.101.3.2 flow: (73 times matched) sour addr: 202.101.1.2/255.255.255.255 port: 0 protocol: GRE dest addr: 202.101.3.2/255.255.255.255 port: 0 protocol: GRE [inbound ESP SAs] spi: 2624895419 (0x9c74b9bb) proposal: ESP-ENCRYPT-DES ESP-AUTH-MD5 sa remaining key duration (bytes/sec): 1887433796/3385 max received sequence-number: 35 udp encapsulation used for nat traversal: N [outbound ESP SAs]

H3C路由器NAT典型配置案例

H3C路由器NAT典型配置案列(史上最详细) 神马CCIE,H3CIE,HCIE等网络工程师日常实施运维必备,您明白的。 1、11 NAT典型配置举例 1、11、1 内网用户通过NAT地址访问外网(静态地址转换) 1、组网需求 内部网络用户10、110、10、8/24使用外网地址202、38、1、100访问Internet、2、组网图 图1-5 静态地址转换典型配置组网图 3、配置步骤 # 依照组网图配置各接口的IP地址,具体配置过程略。 #配置内网IP地址10、110、10、8到外网地址202、38、1、100之间的一对一静态地址转换映射。 system-view [Router] nat static outbound10、110、10、8202、38、1、100 # 使配置的静态地址转换在接口GigabitEthernet1/2上生效、 [Router] interface gigabitethernet1/2 [Router—GigabitEthernet1/2] nat static enable [Router—GigabitEthernet1/2] quit 4、验证配置 #以上配置完成后,内网主机能够访问外网服务器。通过查看如下显示信息,能够验证以上配置成功、 [Router]displaynatstatic Static NATmappings: There are 1 outboundstaticNAT mappings、 IP—to—IP: LocalIP:10、110、10、8 Global IP: 202、38、1、100 Interfaces enabledwith staticNAT: There are 1interfacesenabled with staticNAT、 Interface: GigabitEthernet1/2 # 通过以下显示命令,能够看到Host访问某外网服务器时生成NAT会话信息。 [Router] display natsession verbose

H3C路由器配置命令

telnet 防火墙IP地址 用户名 密码 --进入普通用户权限-- --在此命令下可输入一般命令-- --可用?看有哪些命令和命令的作用-- system-view --进入超级管理员权限界面-- --此提示符下可输绝大部分命令-- --(极少数需要在com终端输入)-- quit --退出当前状态,返回上一级-- 一般命令(不一定要把命令写全) display current 展示当前配置 acl number 3050 进入访问控制列表3050号 rule 66 permit ip ........ 在当前访问控制表增加或修改规则66号 rule的具体用法可用rule ?一步步显示出来,亦可参考我原写的命令 我原配置需要涉及的部分 1.ip和mac绑定,绑定方法具体看一下参数文件你就可明白 2.策略号3050 在该条策略中如有permit就是允许你指定的ip或ip段上网 3.策略号3051和305作用是限流 在该策略号具体用法可参考其中的rule规则 最后是save 否则一重启这些改动就会无效 sH3C路由器 ##################################################################### 1、system-view 进入系统视图模式 2、sysname R1 为设备命名为R1 3、display ip routing-table 显示当前路由表 4、 language-mode Chinese|English 中英文切换 5、interface Ethernet 0/0 进入以太网端口视图

6、 ip address 192.168.1.1 255.255.255.0 配置IP地址和子网掩码 7、 undo shutdown 打开以太网端口 8、 shutdown 关闭以太网端口 9、 quit 退出当前视图模式 10、 ip route-static 192.168.2.0 255.255.255.0 192.168.12.2 description To.R2 配置静态路由 11、 ip route-static 0.0.0.0 0.0.0.0 192.168.12.2 description To.R2 配置默认的路由 H3C S3100 Switch H3C S3600 Switch H3C MSR 20-20 Router ##################################################################### 1、调整超级终端的显示字号; 2、捕获超级终端操作命令行,以备日后查对; 3、 language-mode Chinese|English 中英文切换; 4、复制命令到超级终端命令行,粘贴到主机; 5、交换机清除配置 :reset save ;reboot ; 6、路由器、交换机配置时不能掉电,连通测试前一定要 检查网络的连通性,不要犯最低级的错误。 7、192.168.1.1/24 等同 192.168.1.1 255.255.255.0;在配置交换机和路由器时, 192.168.1.1 255.255.255.0 可以写成: 192.168.1.1 24 8、设备命名规则:地名-设备名-系列号例:PingGu-R-S3600

相关文档
最新文档