close

CCNA實務 SCENARIO I.
背景:公司之大廳有兩部電腦供客戶使用上網,現有一個HACKER欲拔除其中一台PC之網路線接上配自己的NB 請阻止他這麼做!

裝置架構:

作業1-0  

小提示:
1. 先讓 PC0, PC1, PC2(HACK), PC3 都要能互通.


2. 再加指令在 Switch1上
3. 接著讓:
a. PC0, 還是可以通PC1和2
b. PC0, 不能通PC3
(P.S. IP CONFIG因無ROUTE 不需GW)

 

關鍵技術:
Switchport PORT-SECURITY
Maximnu 1
STICKY.

解:
Switch>en
Switch#conf t
Switch(config)#interface fa0/2
Switch(config-if)#switchport mode access
Switch(config-if)#switchport port-security
Switch(config-if)#switchport port-security maximum 2 
Switch(config-if)#switchport port-security mac-address sticky 
Switch(config-if)#switchport port-security violation restrict

 

接下來嘗試PING先將原有PC MAC寫入SWITCH中。
*注意:不可先PING PC3-HACKER (建議可以先將PC-HACK端的連線拔除)

 

 *查看 SWITCH MAC TABLE 內,會發現PC3(HACKER)的MAC並不會存在(不寫入SWITCH內)。

 

 附註:
switchport port-security violation 含有三種模式 protect , restrict , shutdown
protect: 丟棄資料包,不發警告
restrict: 丟棄數據包,在console發警告
shutdown: 關閉埠為err-disable狀態,除非管理員手工啟動,否則該埠失效

如果使用指令" switchport port-security violation shutdown " 會把port關閉。 (關閉port為err-disable狀態,除非管理員手工啟動,否則該埠失效)
需要手動開啟否則該port永久失效
復原方式:手動重啟介面(shutdown後在no shutdown)或透過errdisable recovery恢復 

 

參考網站:

http://www.mikotek.com.tw/suppor/suppor_s5.htm

http://blog.xuite.net/luecat/tools/17922758-%E5%9C%A8+Switch+Port%E4%B8%8A%E9%8E%96mac+-+port+security

 

http://systw.net/note/af/sblog/more.php?id=92

arrow
arrow
    文章標籤
    CCNA
    全站熱搜

    徐子欽 發表在 痞客邦 留言(0) 人氣()