>> switching security <<
1. port-security
설정 위치 : access swtich
옵션 : maximum , sticky , static mac 지정
2. port별 트래픽 제어
설정 위치 : access switch
종류 : storm control , prtected port , port blocking
3. STP 공격 차단
설정 위치 : access / ditribute switch
종류 : BPDU guard , Root guard
4. DHCP snooping
: DHCP에 대한 감시
5. ARP snooping
: ARP spoofing감시
6. IP Source guard
7. ACL : IP acl , mac acl (=vlan map)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>Switch-security2.txt에
---------------------------------------------------------------------
1. port-security
- mac address 정적 설정 : server와 연결된 port에 설정
- 그외 access port : 학습 mac address 제한
- client pc(hosts)연결시 : sticky로 mac address 학습하도록 설정
@ [Router]fa0/0-------fa0/24 [switch] fa0/3------[server]
Router fa0/0 ip : 10.10.10.1/24
server ip : 10.10.10.10/24
server mac : 0000.0000.0001
switch 설정
conf t
int fa0/3
switchport
switchport mode access
switchport port-security mac-address 0000.0000.0001 //정적mac주소 설정
switchport port-security //활성화
end
show port-security
show port-security fa0/3
show mac-address
-> 0000.0000.0001이 아닌 다른 server를 연결할경우, MAC address오류로
자동으로 interface fa0/3이 shutdown 됨.
확인: show int fa0/3
show interface status err-disabled
@ [Router]fa0/0----------------fa0/24[Switch]fa0/10----------[PC-hosts]
switch 설정
conf t
int fa0/10
switchport mode access
switchport port-security maximum 1
//fa0/10에 hub연결시 hub port수만큼 해줌
//fa0/10에 다른 switch연결시 switch포트수+1(스위치자체mac)-> 수만큼 설정
switchport port-security //활성화
end
show port-security
show port-security address
2. port-별 트래픽 제어
2-1. 과다트래픽 제어 storm-contrl : [switch] fa0/0 <-------(in X 제어-유니/멀티/브로드캐스트)
2-2. 포트차단 port-blocking : [switch] fa0/24 --------->(out X 제어-유니/멀티캐스트)
2-3. 방어포트 protect port : fa0/22 [switch] fa0/23
↔ O fa0/24 (↕X -유니/멀티/브로드캐스트)
2-1 storm contrl
: 유니캐스트 , 멀티캐스트 , 브로드캐스트 트래픽이 1초 이상 특정 수준 이상으로
많이 수신되었을 때 일시적 차단,
[Router]-----[switch]fa0/24-----[PC]
스위치 설정
conf t
int fa0/24
storm-control braodcast level 30 //30%이상의 broadcast 발생시 shutdown
또는
storm-control unicast level 10 //10%이상의 bradcast 발생시 shutdown
또는
storm-control multicast level 20 //20%이상의 bradcast 발생시 shutdown
2-2. protected port 방어포트
방어포트로 설정된 port끼리 차단됨 (nui/multi/braod) ISP에서 사용자들끼리통신제한, 게이트와는가능
show int fa0/10 swtichport
.... 생략
Protected : true
.... 생략
[Router]--------fa0/1[switch] fa0/10 (방어포트)-------------pc
fa0/11(방어포트)-------------pc
switch fa0/10 <---X---> fa0/11 방어포트끼리 통신안됨.
switch fa0/10 <---O---> fa0/1 방어포트와 비방어포트끼리 통신가능
switch fa0/10 <---O---> fa0/11 방어포트와 비방어포트끼리 통신가능
2-3 포트차단 port-blocking
: 목적지 주소가 MAC 주소 table에 없는 flooding 하는 것 차단.
show int fa0/1 switchport
.....생략
Unknown unicast blocked : enabled
Unknown multicast blocked : enabled
[Router]--------fa0/1 [swtich] -------Host(보통서버)
스위치 설정
conf t
int fa0/1
switchport block unicast
switchport block multicast
end
3. STP 공격차단
3-1 BPDU guard : PC와 같은 종단장치가 접속된 포트에서 BPUD를 수신하지 못하게 함
스위치 설정
conf t
spanning-tree portfast bpduguard defualt //portfast가 설정된 포트에만 작동
또는
conf t
int fa0/10
spanning-tree bpduguard enable
end
3-2. 가드 루트 root guard
특정 포트에 접속된 네트워크 스위치들은 로트스위치가 될수없도록
[swtich1-루트스위치]fa0/1--------------fa0/24[switch2]
분배계층간에
Root sw Pri ------------Root sw Second
- ----
---- -sw(이거는 루트스위치가될일이없다)
루트스위치에서 설정
switch1#conf t
int fa0/1
spanning-tree guard root
exit
spanning-tree vlan 1 priority 0
end
show spanning-tree vlan 1
show int fa0/1
... is down, line protcol is down (err-disabled)
show int status err-disabled >>>>>>> 에러원인까지 보여줌
int ..... Reason
fa0/1 rootguard
fa0/10 bpdu guard /확인
****inteface down시 해결하는 방법
-수동해결 >>>>>원인제거 하고
int fa0/1
shutdown
no shutdown
end
show ip int brief
show int fa0/1
-자동해결
errdisable recovery cause root guard
errdisable recovery cause bpdu guard
errdisable recovery cause interval 120 //2분후 자동으로 up
@acess switch인 경우
access port : int fax/x
swtichport mode access
spanning-tree portfast
spanning-tree bpdugard enable
port-security mac-address sticky
port-security maximum 1
port-security
trunk port : int fax/x
switchport mode trunk
swtichport guard root //root switch에서)
exit
spanning-tree vlan x root primary
spanning-tree vlan x priority 0 //root primary switch에서)
또는
spanning-tree vlan x root secondary
spanning-tree vlan x priority 4096 //root secondary switch에서)
'보안 > Network' 카테고리의 다른 글
SynFlooding 방어 (0) | 2011.07.18 |
---|---|
스위치 보안정리 2 (0) | 2011.07.13 |
Linux kernel parameter 설정(네트워크) (0) | 2011.07.13 |
라우터 디폴트 셋팅 (0) | 2011.07.06 |
[Router] 라우터의 보안 관련 요소들 (0) | 2011.07.06 |