Juniper srx防火墙NAT配置

一、基础操作说明:

1、  设备恢复出厂化

root# load factory-default

root# set system root-authentication plain-text-password

root# commit

root> request system reboot

2、  基本配置

2.1 配置主机名

root# set system host-name SRX1400

2.2设置时区

[email protected]# set system time-zoneAsia/Shanghai

2.3设置时间

[email protected]# run set date 201508011549.21

2.4设置dns

[email protected]# set system name-server202.l06.0.20

2.5设置接口IP

[email protected]# set interfaces ge-0/0/0 unit0 family inet address 10.0.0.10/24

2.6设置默认路由

[email protected]# set routing-options staticroute 0.0.0.0/0  next-hop 10.0.0.254

2.7创建登陆用户

[email protected]# set system login user adminclass super-user authentication plain-text-password

2.8创建安全Zone

[email protected]# set security zonessecurity-zone untrust

2.9接口加入zone

[email protected]# set security zones security-zoneuntrust interfaces  ge-0/0/0.0

2.10业务口放行icmp

[email protected]#set security zones security-zone untrust interfaces  ge-0/0/0.0 host-inbound-traffic system-services ping

说明:默认情况下,除管理口外的业务口是无法ping通的,需要放行icmp。

二、juniper srx nat

1、NAT的类型

1.1 source nat :interface

1.2 source nat :pool

1.3 destination nat

1.4 static nat

2、配置实例

2.1 基于接口的source nat

[email protected]# set security nat sourcerule-set 1 from zone trust

[email protected]# set security nat sourcerule-set 1 to zone untrust

[email protected]# set security nat sourcerule-set 1 rule rule1 match source-address 0.0.0.0/0 destination-address 0.0.0.0/0

[email protected]# set security nat sourcerule-set 1 rule rule1 then source-nat interface

默认police

policy default-permit {

match {

source-address any;

destination-address any;

application any;

}

then {

permit;

}

}

2.2基于地址池的source nat

[email protected]# set security nat source poolisp address 10.0.0.20 to 10.0.30

[email protected]# set security nat sourcerule-set 1 from zone trust

[email protected]# set security nat sourcerule-set 1 to zone untrust

[email protected]# set security nat sourcerule-set 1 rule rule1 match source-address 0.0.0.0/0 destination-address 0.0.0.0/0

[email protected]# set security nat sourcerule-set 1 rule rule1 then source-nat pool isp

[email protected]# set security nat proxy-arpinterface ge-0/0/0 address 10.0.0.20 to 10.0.0.30

2.3 destination nat 配置

[email protected]# set security nat destinationpool dst-nat-pool-1 address 172.16.1.1/32

[email protected]# set security nat destinationpool dst-nat-pool-1 address port 80

[email protected]# set security nat destinationrule-set rs1 from zone untrust

[email protected]# set security nat destinationrule-set rs1 rule 1 match destination-address 10.0.0.100/32

[email protected]# set security nat destinationpool dst-nat-pool-1 address port 80

[email protected]# set security nat proxy-arpinterface ge-0/0/0.0 address 10.0.0.100/32

[email protected]# set security address-bookglobal address web 172.16.1.1/32

[email protected]# set security nat destinationrule-set rs1 rule 1 then destination-nat pool dst-nat-pool-1

[email protected]# set security policiesfrom-zone untrust to-zone trust policy web match source-address any

[email protected]# set security policiesfrom-zone untrust to-zone trust policy web match destination-address web  match application any

[email protected]# set security policiesfrom-zone untrust to-zone trust policy

[email protected]# set security policiesfrom-zone untrust to-zone trust policy web then permit

[email protected]# insert security policiesfrom-zone untrust to-zone trust policy web before policy default-deny

2.4 static nat配置

[email protected]# set security nat staticrule-set rs1 from zone untrust

[email protected]# set security nat staticrule-set rs1 rule r1 match destination-address 10.0.0.100/32

[email protected]# set security nat staticrule-set rs1 rule r1 then static-nat prefix 172.16.1.1/32

[email protected]# set security nat proxy-arpinterface ge-0/0/0.0 address 10.0.0.100/32

[email protected]# set security address-bookglobal address web 172.16.1.1/32

[email protected]# set security policiesfrom-zone untrust to-zone untrust web match source-address any destination-addressweb application any

[email protected]# set security policiesfrom-zone untrust to-zone trust policy web then permit

[email protected]# insert security policiesfrom-zone untrust to-zone trust web before policy default-deny

时间: 2024-10-29 10:45:39

Juniper srx防火墙NAT配置的相关文章

juniper SRX防火墙NAT测试

1.测试拓扑: 2.测试总结: 3.基本配置: A.路由器R1: interface Ethernet0/0  ip address 202.100.1.1 255.255.255.0  no shut B.防火墙SRX: ①配置接口地址: set interfacesge-0/0/0.0family inetaddress 202.100.1.10/24 set interfacesge-0/0/1.0family inetaddress 10.1.1.10/24 set interfaces

Juniper SRX防火墙HA配置

一.实验环境介绍1)vsrx 12.1X47-D20.7 二.实验拓扑 vSRXA1与vSRXA2之间建议Chassis Clusterge-0/0/0为带外管理接口(系列默认,不可改)ge-0/0/1为control-link(系统配置,不可改)ge-0/0/4为data-link(手工配置,可改)control-link与data-link采用背靠背的连接方式. 在低端的SRX防火墙带外管理接口.控制接口.数据接口都是业务接口.在高端的SRX防火墙管理接口.控制接口即为专用接口,只有数据接口

Juniper SRX防火墙-NAT学习笔记!

Junos NAT第一部分:SRX NAT介绍第二部分:Source NAT:Interface NAT第三部分:Source NAT:Address Pools第四部分:Destination NAT第五部分:Static NAT--------------------------------------------------SRX Nat介绍1.Source NAT   //转换源的NAT,NAT+Gloabl2.Destination NAT  //Static pat3.Static

juniper SRX防火墙DHCP配置

set system services dhcp pool 192.168.68.0/24 address-range low 192.168.68.2set system services dhcp pool 192.168.68.0/24 address-range high 192.168.68.254set system services dhcp pool 192.168.68.0/24 default-lease-time 36000set system services dhcp

Juniper老司机经验谈(SRX防火墙NAT与策略篇)视频课程上线了

继前面的<Juniper老司机经验谈(SRX防火墙优化篇)>之后,Juniper老司机经验谈(SRX防火墙NAT与策略篇)第二部视频课程也录制上线了 1.两个课程完全独立又相结合, SRX防火墙优化篇是针对防火墙双机.配置优化内容. SRX防火墙NAT与策略篇则是针对防火NAT.策略内容 . 两部除了前几4单节基础理论与模拟环境搭建部分一样外,其他内容完全不重叠. 2.本课程内容: 大家在QQ群.论坛里经常提的问题,许多人对SRX使用中NAT\策略问题不是很理解,实际工作中碰见太多问题,惹出了

Juniper SRX防火墙系统会话链接的清除

Juniper SRX防火墙系统会话链接的清除 维护Juniper防火墙SRX系列防火墙,一段时间后,发现防火墙老是有时候登录不上去,有时候可以登录. 查看用户的时候,发现,系统挂了很多连接会话,怪不得老是无法登录,资料被消耗了. 用户并不多: {primary:node0}[email protected]> show system users node0:---------------------------------------------------------------------

juniper srx 动态VPN 配置

juniper srx系列防火墙的动态VPN又叫dynamic vpn ,可以通过电脑客户端远程拨入到设备所在网络中.目前低端系列的防火墙如srx100 srx210 srx240 srx550 srx650设备默认支持两个动态VPN并发授权,超过两个授权需要开通相应的license .srx300系列需要高版本才能支持,前段时间测试过300系列15.1D49是不支持动态VPN的,好像需要升级到D51版本以上. 开启https set system services web-management

华为USG防火墙NAT配置

实验拓扑 实验环境 FW1模拟公司的出口防火墙,R1和R2模拟公司内网设备,R1在trust区域.R2在dmz区域.R3模拟运营商网络. 实验需求 对R1的loopback 0 接口做动态NAT转换 对R1的G0/0/0接口做静态PAT转换 对R2的loopback 0 接口做静态NAT转换 对R2的G0/0/0接口做静态端口映射 网络地址规划 R1  G0/0/0  IP:11.0.0.2/24 R1 loopback 0 IP:192.168.10.1/24 R2 loopback 0 IP

ASA 防火墙nat配置

1.防火墙上动态nat配置 nat (inside) id号 192.168.20.0 255.255.255.0    //宣告要转化的网段// global (outsie) id号 12.0.0.2-12.0.0.6        //宣告转化后的网段// 查看nat  为show xlate deatil 2.防火墙上动态pat配置 nat (inside) id号 192.168.20.0 255.255.255.0    //宣告需要转换的网段// global (outside)