多平台统一管理软件接口,如何实现多平台统一管理软件接口
447
2022-09-09
防火墙动态NAT转换(nat动态地址转换)
实验环境:
实验步骤:
配置接口ip静态路由以及默认路由
iou1命令如下:
IOU1(config)#interface ethernet 0/0IOU1(config-if)#du fuIOU1(config-if)#ip address 200.1.1.2 255.255.255.0IOU1(config-if)#no shutdown IOU1(config-if)#exIOU1(config)#interface loopback 0IOU1(config-if)#ip address 218.85.152.99 255.255.255.255IOU1(config-if)#no shutdown IOU1(config-if)#exIOU1(config)#ip route 0.0.0.0 0.0.0.0 200.1.1.1
iou2命令如下:
IOU2(config)#interface ethernet 0/0 IOU2(config-if)#du fuIOU2(config-if)#ip address 172.16.1.1 255.255.255.0IOU2(config-if)#no shutdown IOU2(config-if)#exIOU2(config)#interface loopback 0 IOU2(config-if)#ip address 172.16.88.11 255.255.255.255IOU2(config-if)#no shutdown IOU2(config-if)#exIOU2(config)#ip route 0.0.0.0 0.0.0.0 172.16.1.254
iou3命令如下:
IOU3(config)#interface ethernet 0/0IOU3(config-if)#du fu IOU3(config-if)#ip address 192.168.0.11 255.255.255.0IOU3(config-if)#no shutdown IOU3(config-if)#exIOU3(config)#interface loopback 0IOU3(config-if)#ip address 192.168.1.11 255.255.255.255IOU3(config-if)#no shutdown IOU3(config-if)#exIOU3(config)#ip route 0.0.0.0 0.0.0.0 192.168.0.254
防火墙命令如下:
ciscoasa(config)# interface gigabitEthernet 0ciscoasa(config-if)# nameif outsideciscoasa(config-if)# security-level 0ciscoasa(config-if)# ip address 200.1.1.1 255.255.255.0ciscoasa(config-if)# no shuciscoasa(config-if)# exciscoasa(config)# interface gigabitEthernet 1ciscoasa(config-if)# nameif insideciscoasa(config-if)# security-level 100ciscoasa(config-if)# ip address 172.16.1.254 255.255.255.0ciscoasa(config-if)# no shuciscoasa(config-if)# exciscoasa(config)# interface gigabitEthernet 2ciscoasa(config-if)# nameif dmzciscoasa(config-if)# security-level 50ciscoasa(config-if)# ip address 192.168.0.254 255.255.255.0ciscoasa(config-if)# no shuciscoasa(config-if)# exciscoasa(config)# route outside 0 0 200.1.1.0 ciscoasa(config)# route dmz 192.168.1.0 255.255.255.0 192.168.0.11ciscoasa(config)# route inside 172.16.88.0 255.255.255.0 172.16.1.1
配置telnet
iou1命令如下:
IOU1(config)#username bdqn privilege 15 password ciscoIOU1(config)#line vty 0 4IOU1(config-line)#login local IOU1(config-line)#transport input telnet
iou2命令如下:
IOU2(config)#username bdqn privilege 15 password ciscoIOU2(config)#line vty 0 4IOU2(config-line)#login local IOU2(config-line)#transport input telnet
iou3命令如下;
IOU3(config)#username bdqn privilege 15 password ciscoIOU3(config)#line vty 0 4IOU3(config-line)#login local IOU3(config-line)#transport input telnet
在防火墙上面配置动态NAT
ciscoasa(config)# object network out-poolciscoasa(config-network-object)# range 200.1.1.10 200.1.1.20ciscoasa(config-network-object)# exitciscoasa(config)# object network in-ldciscoasa(config-network-object)# subnet 172.16.88.0 255.255.255.0ciscoasa(config-network-object)# exciscoasa(config)# object network in-xdciscoasa(config-network-object)# subnet 172.16.1.0 255.255.255.0ciscoasa(config-network-object)# exciscoasa(config)# object network dmz-1ciscoasa(config-network-object)# subnet 192.168.0.0 255.255.255.0ciscoasa(config-network-object)# exciscoasa(config)# object network dmz-2ciscoasa(config-network-object)# subnet 192.168.1.0 255.255.255.0ciscoasa(config-network-object)# exciscoasa(config)# object-group network in-lanciscoasa(config-network-object-group)# network-object object -ldciscoasa(config-network-object-group)# network-object object -xdciscoasa(config-network-object-group)# exciscoasa(config)# object-group network dmz-lanciscoasa(config-network-object-group)# network-object object dmz-1ciscoasa(config-network-object-group)# network-object object dmz-2ciscoasa(config-network-object-group)# exitciscoasa(config)# nat (inside,outside) source dynamic in-lan out-poolciscoasa(config)# nat (dmz,outside) source dynamic dmz-lan out-pool
使用telnet命令测试
在防火墙上使用show xlate 查看经过防火墙telnet的流量
动态NAT配置完成
配置PAT
首先先把动态nat的两条命令删除
ciscoasa(config)# no nat (inside,outside) source dynamic in-lan out-poolciscoasa(config)# no nat (dmz,outside) source dynamic dmz-lan out-pool
PAT多内网架构,多个网段,多个zone,直接使用外网接口
ciscoasa(config)# nat (inside,outside) source dynamic in-lan interface ciscoasa(config)# nat (dmz,outside) source dynamic dmz-lan interface
使用telnet测试
在防火墙上使用show xlate 查看经过防火墙telnet的流量
现将上面nat命令no掉
ciscoasa(config)# no nat (inside,outside) source dynamic in-lan interface ciscoasa(config)# no nat (dmz,outside) source dynamic dmz-lan interface
配置多内网架构使用一个指定外网IP
ciscoasa(config)# object network out-pat3ciscoasa(config-network-object)# host 200.1.1.3ciscoasa(config-network-object)# exitciscoasa(config)# nat (inside,outside) source dynamic in-ld pat-pool out-pat3ciscoasa(config)# object network out-pool4 ciscoasa(config-network-object)# host 200.1.1.4ciscoasa(config-network-object)# exciscoasa(config)# nat (inside,outside) source dynamic in-xd pat-pool out-pool4
在防火墙上使用show xlate 查看经过防火墙telnet的流量
使用telnet 命令测试
先将上面nat命令no掉
ciscoasa(config)# no nat (inside,outside) source dynamic in-ld pat-pool out-pat3ciscoasa(config)# nat (inside,outside) source dynamic in-xd pat-pool out-pool4
先动态NAT。最后用指定IP做PAT
ciscoasa(config)# object network out-poolciscoasa(config-network-object)# range 200.1.1.10 200.1.1.20ciscoasa(config-network-object)# exciscoasa(config)# object network out-pat3ciscoasa(config-network-object)# host 200.1.1.3ciscoasa(config-network-object)# exciscoasa(config)# object-group network out-natciscoasa(config-network-object-group)# network-object object out-pat3ciscoasa(config-network-object-group)# network-object object out-poolciscoasa(config-network-object-group)# exciscoasa(config)# nat (inside,outside) source dynamic in-lan out-nat
使用telnet命令测试
在防火墙上使用show xlate 查看经过防火墙telnet的流量
先将上面nat命令no掉
ciscoasa(config)# nat (inside,outside) source dynamic in-lan out-nat
静态NAT(一对一)
ciscoasa(config)# object network webciscoasa(config-network-object)# host 200.1.1.21ciscoasa(config-network-object)# exciscoasa(config)# object network dmz-webciscoasa(config-network-object)# host 192.168.1.11ciscoasa(config-network-object)# exciscoasa(config)# access-list web extended permit tcp any host 192.168.1.11ciscoasa(config)# access-group web in interface outside ciscoasa(config)# nat (dmz,outside) source static dmz-web web
使用telnet命令测试
在防火墙上使用show xlate 查看经过防火墙telnet的流量
先将上面nat命令no掉
ciscoasa(config)# nat (dmz,outside) source static dmz-web web
端口一对一
ciscoasa(config)# object network teldmzciscoasa(config-network-object)# host 200.1.1.22ciscoasa(config-network-object)# exciscoasa(config)# object network dmz-webciscoasa(config-network-object)# host 192.168.1.11ciscoasa(config-network-object)# exciscoasa(config)# object service telnetciscoasa(config-service-object)# service tcp source eq telnetciscoasa(config-service-object)# ex ciscoasa(config)# nat (dmz,outside) source static dmz-web teldmz service telnet telnet
使用telnet命令测试
在防火墙上使用show xlate 查看经过防火墙telnet的流量
版权声明:本文内容由网络用户投稿,版权归原作者所有,本站不拥有其著作权,亦不承担相应法律责任。如果您发现本站中有涉嫌抄袭或描述失实的内容,请联系我们jiasou666@gmail.com 处理,核实后本网站将在24小时内删除侵权内容。
发表评论
暂时没有评论,来抢沙发吧~