溫馨提示×

溫馨提示×

您好,登錄后才能下訂單哦!

密碼登錄×
登錄注冊×
其他方式登錄
點擊 登錄注冊 即表示同意《億速云用戶服務條款》

ASA防火墻靜態(tài)PAT端口范圍測試

發(fā)布時間:2020-07-05 12:46:16 來源:網(wǎng)絡 閱讀:1396 作者:碧云天 欄目:安全技術

一.測試拓撲

ASA防火墻靜態(tài)PAT端口范圍測試

二.測試思路

1.分別測試tcp和udp的連續(xù)端口PAT

2.再用靜態(tài)端口轉換工具分別將TCP端口和udp端口轉換到某個常用端口進行測試

---tcp轉換到TCP23,用telnet測試

---udp轉換到UDP514,用syslog發(fā)送進行測試

 3.為了測試方便,防火墻只設兩個區(qū)Outside和Inside

---將Inside服務器的TCP1000~2000映射到防火墻Outside口的TCP1000~2000上

---將Inside服務器的UDP1000~2000映射到防火墻Outside口的UPD2000~3000上

4.測試發(fā)現(xiàn)如果TCP端口范圍與UDP端口范圍一樣,第二個NAT配置不上,會報如下錯誤:

 ERROR: NAT unable to reserve ports.

三.基本配置

1.Outside服務器

  IP:202.100.1.8/24

2.防火墻ASA842

interface GigabitEthernet0
nameif Outside
security-level 0
ip address 202.100.1.10 255.255.255.0
!
interface GigabitEthernet1
nameif Inside
security-level 100
ip address 10.1.1.10 255.255.255.0 

3.Intside服務器

  IP:10.1.1.8/24

  GW:10.1.1.10


四.靜態(tài)PAT端口范圍配置

1.定義端口范圍對象

object network  Inside_Server
      host 10.1.1.8

object service tcp_ports
      service tcp destination range 1000 2000

object service udp_ports
      service udp destination range 2000 3000

2.配置twice-nat

nat (outside,inside) source static any any destination static interface  Inside_Server service tcp_ports tcp_ports

nat (outside,inside) source static any any destination static interface  Inside_Server service udp_ports udp_ports 

3.配置并應用防火墻策略

access-list Outside extended permit tcp any object Inside_Server range 1000 2000
access-list Outside extended permit udp any object Inside_Server range 2000 3000

access-group Outside in interface Outside 

4.測試驗證

---可以用多種方式驗證,如果進行靜態(tài)端口轉換嫌麻煩,可以直接抓包驗證

ASA防火墻靜態(tài)PAT端口范圍測試

ASA防火墻靜態(tài)PAT端口范圍測試

向AI問一下細節(jié)

免責聲明:本站發(fā)布的內容(圖片、視頻和文字)以原創(chuàng)、轉載和分享為主,文章觀點不代表本網(wǎng)站立場,如果涉及侵權請聯(lián)系站長郵箱:is@yisu.com進行舉報,并提供相關證據(jù),一經(jīng)查實,將立刻刪除涉嫌侵權內容。

AI