cisco PIX防火墻怎么配置
cisco PIX防火墻怎么配置
思科cisco依靠自身的技術(shù)和對(duì)網(wǎng)絡(luò)經(jīng)濟(jì)模式的深刻理解,使他成為了網(wǎng)絡(luò)應(yīng)用的成功實(shí)踐者之一,他制造的路由器也是全球頂尖的,那么你知道cisco PIX防火墻怎么配置嗎?下面是學(xué)習(xí)啦小編整理的一些關(guān)于cisco PIX防火墻怎么配置的相關(guān)資料,供你參考。
cisco PIX防火墻配置的過(guò)程:
PIX Version 6.3(1)
interface ethernet0 auto 設(shè)定端口0 速率為自動(dòng)
interface ethernet1 100full 設(shè)定端口1 速率為100兆全雙工
interface ethernet2 auto 設(shè)定端口2 速率為自動(dòng)
nameif ethernet0 outside security0 設(shè)
定端口0 名稱(chēng)為 outside 安全級(jí)別為0
nameif ethernet1 inside security100 設(shè)定端口1 名稱(chēng)為 inside 安全級(jí)別為100
nameif ethernet2 dmz security50 設(shè)定端口2 名稱(chēng)為 dmz 安全級(jí)別為50
enable password Dv0yXUGPM3Xt7xVs encrypted 特權(quán)密碼
passwd 2KFQnbNIdI.2KYOU encrypted 登陸密碼
hostname hhyy 設(shè)定防火墻名稱(chēng)
fixup protocol ftp 21
fixup protocol h323 h225 1720
fixup protocol h323 ras 1718-1719
fixup protocol http 80
fixup protocol ils 389
fixup protocol rsh 514
fixup protocol rtsp 554
fixup protocol sip 5060
fixup protocol sip udp 5060
no fixup protocol skinny 2000
fixup protocol smtp 25
fixup protocol sqlnet 1521
允許用戶查看、改變、啟用或禁止一個(gè)服務(wù)或協(xié)議通過(guò)PIX防火墻,防火墻默認(rèn)啟用了一些常見(jiàn)的端口,但對(duì)于ORACLE等專(zhuān)有端口,需要專(zhuān)門(mén)啟用。
names
access-list 101 permit ip 192.168.99.0 255.255.255.0 192.168.170.0 255.255.255.0
access-list 101 permit ip 192.168.12.0 255.255.255.0 192.168.180.0 255.255.255.0
access-list 101 permit ip 192.168.23.0 255.255.255.0 192.168.180.0 255.255.255.0
access-list 101 permit ip 192.168.99.0 255.255.255.0 192.168.101.0 255.255.255.0
建立訪問(wèn)列表,允許特定網(wǎng)段的地址訪問(wèn)某些網(wǎng)段
access-list 120 deny icmp 192.168.2.0 255.255.255.0 any
access-list 120 deny icmp 192.168.3.0 255.255.255.0 any
access-list 120 deny icmp 192.168.4.0 255.255.255.0 any
access-list 120 deny icmp 192.168.5.0 255.255.255.0 any
access-list 120 deny icmp 192.168.6.0 255.255.255.0 any
access-list 120 deny icmp 192.168.7.0 255.255.255.0 any
access-list 120 deny icmp 192.168.8.0 255.255.255.0 any
access-list 120 deny icmp 192.168.9.0 255.255.255.0 any
access-list 120 deny icmp 192.168.10.0 255.255.255.0 any
access-list 120 deny icmp 192.168.11.0 255.255.255.0 any
access-list 120 deny icmp 192.168.12.0 255.255.255.0 any
access-list 120 deny icmp 192.168.13.0 255.255.255.0 any
access-list 120 deny icmp 192.168.14.0 255.255.255.0 any
access-list 120 deny icmp 192.168.15.0 255.255.255.0 any
access-list 120 deny icmp 192.168.16.0 255.255.255.0 any
access-list 120 deny icmp 192.168.17.0 255.255.255.0 any
access-list 120 deny icmp 192.168.18.0 255.255.255.0 any
access-list 120 deny icmp 192.168.19.0 255.255.255.0 any
access-list 120 deny icmp 192.168.20.0 255.255.255.0 any
access-list 120 deny icmp 192.168.21.0 255.255.255.0 any
access-list 120 deny icmp 192.168.22.0 255.255.255.0 any
access-list 120 deny udp any any eq netbios-ns
access-list 120 deny udp any any eq netbios-dgm
access-list 120 deny udp any any eq 4444
access-list 120 deny udp any any eq 1205
access-list 120 deny udp any any eq 1209
access-list 120 deny tcp any any eq 445
access-list 120 deny tcp any any range 135 netbios-ssn
access-list 120 permit ip any any
建立訪問(wèn)列表120防止各個(gè)不同網(wǎng)段之間的ICMP發(fā)包及拒絕135、137等端口之間的通信(主要防止沖擊波病毒)
access-list 110 permit ip 192.168.99.0 255.255.255.0 192.168.101.0 255.255.255.0
pager lines 24
logging on
logging monitor debugging
logging buffered debugging
logging trap notifications
mtu outside 1500
mtu inside 1500
mtu dmz 1500
ip address outside 10.1.1.4 255.255.255.224 設(shè)定外端口地址
ip address inside 192.168.1.254 255.255.255.0 設(shè)定內(nèi)端口地址
ip address dmz 192.168.19.1 255.255.255.0 設(shè)定DMZ端口地址
ip audit info action alarm
ip audit attack action alarm
ip local pool hhyy 192.168.170.1-192.168.170.254
建立名稱(chēng)為hhyy的地址池,起始地址段為:192.168.170.1-192.168.170.254
ip local pool yy 192.168.180.1-192.168.180.254
建立名稱(chēng)為yy 的地址池,起始地址段為:192.168.180.1-192.168.180.254
no failover
failover timeout 0:00:00
failover poll 15
no failover ip address outside
no failover ip address inside
no failover ip address dmz
no pdm history enable
arp timeout 14400
不支持故障切換
global (outside) 1 10.1.1.13-10.1.1.28
global (outside) 1 10.1.1.7-10.1.1.9
global (outside) 1 10.1.1.10
定義內(nèi)部網(wǎng)絡(luò)地址將要翻譯成的全局地址或地址范圍
nat (inside) 0 access-list 101
使得符合訪問(wèn)列表為101地址不通過(guò)翻譯,對(duì)外部網(wǎng)絡(luò)是可見(jiàn)的
nat (inside) 1 192.168.0.0 255.255.0.0 0 0
內(nèi)部網(wǎng)絡(luò)地址翻譯成外部地址
nat (dmz) 1 192.168.0.0 255.255.0.0 0 0
DMZ區(qū)網(wǎng)絡(luò)地址翻譯成外部地址
static (inside,outside) 10.1.1.5 192.168.12.100 netmask 255.255.255.255 0 0
static (inside,outside) 10.1.1.12 192.168.12.158 netmask 255.255.255.255 0 0
static (inside,outside) 10.1.1.3 192.168.2.4 netmask 255.255.255.255 0 0
設(shè)定固定主機(jī)與外網(wǎng)固定IP之間的一對(duì)一靜態(tài)轉(zhuǎn)換
static (dmz,outside) 10.1.1.2 192.168.19.2 netmask 255.255.255.255 0 0
設(shè)定DMZ區(qū)固定主機(jī)與外網(wǎng)固定IP之間的一對(duì)一靜態(tài)轉(zhuǎn)換
static (inside,dmz) 192.168.0.0 192.168.0.0 netmask 255.255.0.0 0 0
設(shè)定內(nèi)網(wǎng)固定主機(jī)與DMZ IP之間的一對(duì)一靜態(tài)轉(zhuǎn)換
static (dmz,outside) 10.1.1.29 192.168.19.3 netmask 255.255.255.255 0 0
設(shè)定DMZ區(qū)固定主機(jī)與外網(wǎng)固定IP之間的一對(duì)一靜態(tài)轉(zhuǎn)換
access-group 120 in interface outside
access-group 120 in interface inside
access-group 120 in interface dmz
將訪問(wèn)列表應(yīng)用于端口
conduit permit tcp host 10.1.1.2 any
conduit permit tcp host 10.1.1.3 any
conduit permit tcp host 10.1.1.12 any
conduit permit tcp host 10.1.1.29 any
設(shè)置管道:允許任何地址對(duì)全局地址進(jìn)行TCP協(xié)議的訪問(wèn)
conduit permit icmp 192.168.99.0 255.255.255.0 any
設(shè)置管道:允許任何地址對(duì)192.168.99.0 255.255.255.0地址進(jìn)行PING測(cè)試
rip outside passive version 2
rip inside passive version 2
route outside 0.0.0.0 0.0.0.0 10.1.1.1
設(shè)定默認(rèn)路由到電信端
route inside 192.168.2.0 255.255.255.0 192.168.1.1 1
route inside 192.168.3.0 255.255.255.0 192.168.1.1 1
route inside 192.168.4.0 255.255.255.0 192.168.1.1 1
route inside 192.168.5.0 255.255.255.0 192.168.1.1 1
route inside 192.168.6.0 255.255.255.0 192.168.1.1 1
route inside 192.168.7.0 255.255.255.0 192.168.1.1 1
route inside 192.168.8.0 255.255.255.0 192.168.1.1 1
route inside 192.168.9.0 255.255.255.0 192.168.1.1 1
route inside 192.168.10.0 255.255.255.0 192.168.1.1 1
route inside 192.168.11.0 255.255.255.0 192.168.1.1 1
設(shè)定路由回指到內(nèi)部的子網(wǎng)
timeout xlate 3:00:00
timeout conn 1:00:00 half-closed 0:10:00 udp 0:02:00 rpc 0:10:00 h225
1:00:00
timeout h323 0:05:00 mgcp 0:05:00 sip 0:30:00 sip_media 0:02:00
timeout uauth 0:05:00 absolute
aaa-server TACACS+ protocol tacacs+
aaa-server RADIUS protocol radius
aaa-server LOCAL protocol local
no snmp-server location
no snmp-server contact
snmp-server community public
no snmp-server enable traps
floodguard enable
sysopt connection permit-ipsec
sysopt connection permit-pptp
service resetinbound
service resetoutside
crypto ipsec transform-set myset esp-des esp-md5-hmac
定義一個(gè)名稱(chēng)為myset的交換集
crypto dynamic-map dynmap 10 set transform-set myset
根據(jù)myset交換集產(chǎn)生名稱(chēng)為dynmap的動(dòng)態(tài)加密圖集(可選)
crypto map 10 ipsec-isakmp dynamic dynmap
將dynmap動(dòng)態(tài)加密圖集應(yīng)用為IPSEC的策略模板(可選)
crypto map 20 ipsec-isakmp
用IKE來(lái)建立IPSEC安全關(guān)聯(lián)以保護(hù)由該加密條目指定的數(shù)據(jù)流
crypto map 20 match address 110
為加密圖指定列表110作為可匹配的列表
crypto map 20 set peer 10.1.1.41
在加密圖條目中指定IPSEC對(duì)等體
crypto map 20 set transform-set myset
指定myset交換集可以被用于加密條目
crypto map client configuration address initiate
指示PIX防火墻試圖為每個(gè)對(duì)等體設(shè)置IP地址
crypto map client configuration address respond
指示PIX防火墻接受來(lái)自任何請(qǐng)求對(duì)等體的IP地址請(qǐng)求
crypto map interface outside
isakmp enable outside
在外部接口啟用IKE協(xié)商
isakmp key ******** address 10.1.1.41 netmask 255.255.255.255
指定預(yù)共享密鑰和遠(yuǎn)端對(duì)等體的地址
isakmp identity address
IKE身份設(shè)置成接口的IP地址
isakmp client configuration address-pool local yy outside
isakmp policy 10 authentication pre-share
指定預(yù)共享密鑰作為認(rèn)證手段
isakmp policy 10 encryption des
指定56位DES作為將被用于IKE策略的加密算法
isakmp policy 10 hash md5
指定MD5 (HMAC變種)作為將被用于IKE策略的散列算法
isakmp policy 10 group 2
指定1024比特Diffie-Hellman組將被用于IKE策略
isakmp policy 10 lifetime 86400
每個(gè)安全關(guān)聯(lián)的生存周期為86400秒(一天)
group cisco idle-time 1800
group pix_ address-pool yy
group pix_ idle-time 1800
group pix_ password ********
group 123 address-pool yy
group 123 idle-time 1800
group 123 password ********
group 456 address-pool yy
group 456 idle-time 1800
group 456 password ********
telnet 192.168.88.144 255.255.255.255 inside
telnet 192.168.88.154 255.255.255.255 inside
telnet timeout 5
ssh timeout 5
console timeout 0
vpdn group 1 accept dialin pptp
vpdn group 1 ppp authentication pap
vpdn group 1 ppp authentication chap
vpdn group 1 ppp authentication mschap
vpdn group 1 ppp encryption mppe 40
vpdn group 1 client configuration address local hhyy
vpdn group 1 pptp echo 60
vpdn group 1 client authentication local
vpdn username cisco password *********
vpdn enable outside
username cisco password 3USUcOPFUiMCO4Jk encrypted privilege 2
client group cisco_ password ********
client username pix password ********
terminal width 80
Cryptochecksum:9524a589b608c79d50f7c302b81bdfa4b