一、实验拓扑:
22-思科防火墙:Dynamic Identity NAT、Static Identity NAT_第1张图片
二、实验要求:
实验一:Dinamic Identity NAT
R1、R2都有默认路由,下一跳为ASA对应的接口地址。
实验二:Static Identity NAT
三、命令部署:
实验一:
1、清除上个实验的access-list:
ASA(config)# clear configure access-list
ASA(config)# show access-list

2、Inside内部署Dinamic Identity NAT使得10.1.1.1~10.1.1.100转换到Outside时,转换到自身:
ASA(config)# object network in-yuan
ASA(config-network-object)# range 10.1.1.1 10.1.1.100
ASA(config-network-object)# nat (inside,outside) static in-jing
验证:
R2#telnet 202.100.1.1
Trying 202.100.1.1 ... Open
User Access Verification
Username: aa
Password:
R1>
R1#show users
Line User Host(s) Idle Location

  • 0 con 0 idle 00:00:00
    66 vty 0 aa idle 00:00:07 10.1.1.32
    ASA# show xlate
    1 in use, 1 most used
    Flags: D - DNS, i - dynamic, r - portmap, s - static, I - identity, T - twice
    NAT from inside:10.1.1.2 to outside:10.1.1.32 flags i idle 0:01:00 timeout 1:00:00 //证明是有转换的,但是转换后地址不能对应,但是静态是可以做到对应的。

实验二:
1、Inside内部署Statc Identity NAT使得10.1.1.2转换到Outside时,转换到自身:

ASA(config)# object network in-jing
ASA(config-network-object)# host 10.1.1.2
ASA(config-network-object)# nat (inside,outside) dynamic in-jing

验证:
R2#telnet 202.100.1.1
Trying 202.100.1.1 ... Open
User Access Verification
Username: aa
Password:
R1>

R1#show users
Line User Host(s) Idle Location

  • 0 con 0 idle 00:00:00
    66 vty 0 aa idle 00:00:03 10.1.1.2
    Static Identity NAT:一般用在有×××的时候用到这种转换