패킷 캡처를 위한 IDP 유틸리티
패킷 캡처용 IDP 유틸리티는 IDP 이벤트와 관련된 패킷 데이터를 캡처, 관리 및 분석할 수 있는 특수 도구입니다.
패킷 캡처 유틸리티는 네트워크 트래픽을 기록하는 패킷 캡처 파일을 분석하는 데 사용됩니다. 네트워크 관리자는 IDP 유틸리티를 사용하여 이러한 패킷 캡처 파일을 검사하여 네트워크 트래픽 내의 잠재적인 보안 위협이나 이상 징후를 식별할 수 있습니다.
기능 탐색기를 사용하여 특정 기능에 대한 플랫폼 및 릴리스 지원을 확인하십시오.
플랫폼과 관련된 참고 사항은 플랫폼별 패킷 캡처 동작 섹션을 검토합니다.
패킷 캡처
IDP의 패킷 캡처는 네트워크 트래픽을 캡처하고 분석하여 보안 위협을 탐지하고 방지하는 기능입니다.
패킷 캡처 트래픽에 대해서만 컨텍스트 및 관련 데이터를 표시하고 지우기 위해 CLI 지원이 제공되므로 IDP 검증 프로세스가 개선됩니다.
inet 모드 또는 투명 모드에서 패킷 캡처 유틸리티를 실행하여 프로토콜 컨텍스트를 생성할 수 있습니다. UNIX 셸 프롬프트(%)에서 명령줄 패킷 캡처 피더 유틸리티 도구를 실행해야 합니다.
패킷 캡처 피더 유틸리티는 패킷이 공급될 트래픽 인터페이스에서 사용할 수 있는 한 쌍의 소스 및 대상 IPv4 주소를 사용합니다. 또한 패킷 캡처 피더 유틸리티는 이러한 PCAP가 삽입되는 인터페이스에 대해 구성된 IPV4 주소를 사용합니다. PCAP가 이러한 인터페이스에 공급되면 PCAP 및 데이터와 관련된 컨텍스트 목록이 컨텍스트와 일치합니다. 컨텍스트, 히트 및 관련 데이터는 패킷 캡처 피더에서 생성되는 트래픽에 대해서만 표시됩니다. 실시간 트래픽 통계는 캡처되지 않습니다. 패킷을 공급하는 동안 인터페이스의 서브넷 IP에 패킷을 공급해야 합니다. 인터페이스 IP에 패킷을 공급하는 경우 IDP 보안 처리가 컨텍스트를 감지하지 못할 수 있습니다. 인터페이스 IP를 제외한 다른 모든 서브넷 IP 주소를 사용할 수 있습니다.
패킷 캡처 피더 유틸리티 도구를 통해 새로운 PCAP를 실행하기 전에 다음 명확한 컨텍스트 명령을 사용하여 기존 컨텍스트와 데이터를 지웁니다.
[edit security] user@host> clear security idp attack context user@host> clear security flow session interface <intf1> user@host> clear security flow session interface <intf2> user@host> clear security flow session idp user@host> clear security idp attack table
Inet 모드 패킷 캡처 피더에 사용되는 샘플 명령:
% pcapfeed –verbose --interface-ip1 5.0.0.13 --interface-ip2 15.0.0.14 --pcap-ip1 6.0.0.1 --pcap-ip2 7.0.0.1 --interface1 ge-0/0/6 --interface2 ge-0/0/7 --pcap /var/tmp/http.pcap
또는
% pcapfeed –quiet --interface-ip1 5.0.0.13 --interface-ip2 15.0.0.14 --pcap-ip1 6.0.0.1 --pcap-ip2 7.0.0.1 --interface1 ge-0/0/6 --interface2 ge-0/0/7 --pcap /var/tmp/http.pcap
투명 모드 패킷 캡처 피더에 사용되는 샘플 명령:
% pcapfeed –verbose –transparent --pcap-ip1 6.0.0.1 --pcap-ip2 7.0.0.1 --interface1 ge-0/0/6 --interface2 ge-0/0/7 --pcap /var/tmp/http.pcap
또는
% pcapfeed –quiet –transparent --pcap-ip1 6.0.0.1 --pcap-ip2 7.0.0.1 --interface1 ge-0/0/6 --interface2 ge-0/0/7 --pcap /var/tmp/http.pcap
표 1 은 위에 제공된 샘플 출력의 PCAP 피더 도구 필드를 정의합니다.
Fields |
Description |
pcap --조용한 |
로그가 콘솔에 표시되지 않도록 합니다. |
pcap --자세한 내용 |
로그가 콘솔에 표시되도록 활성화합니다. |
인터페이스-ip1 |
패킷 캡처 패킷을 공급하기 위한 첫 번째 인터페이스의 IP 주소 |
인터페이스-IP2 |
패킷 캡처 패킷을 공급하기 위한 다른 인터페이스의 IP 주소 |
pcap-ip1 |
패킷 캡처에 표시되는 IP 주소 |
PCAP-IP2 |
패킷 캡처에 표시되는 다른 IP 주소 |
인터페이스1 |
보안 디바이스의 인터페이스 1 |
인터페이스2 |
보안 디바이스의 인터페이스 1 |
패킷 캡처 피더는 다음을 지원하지 않습니다.
IPv6
FTP와 같은 다중 채널 프로토콜
예: 패킷 캡처 피더 구성
이 예에서는 패킷 캡처(PCAP) 피더를 inet 모드로 실행하여 프로토콜 컨텍스트를 생성하는 방법을 설명합니다.
요구 사항
시작하기 전에:
네트워크 인터페이스를 구성합니다.
개요
관련 IDP 정책과 함께 PCAP 피더를 실행하여 관련 프로토콜 컨텍스트를 가져옵니다. 이 예에서 PCAP는 조용한 모드에서 pcap-ip1 6.0.0.1 및 pcap-ip2 7.0.0.1을 사용하여 공급됩니다.
구성
절차
CLI 빠른 구성
이 예를 빠르게 구성하려면, 아래 명령을 복사하여 텍스트 파일로 붙여 넣은 다음 모든 라인브레이크를 제거하고, 네트워크 구성을 일치하는 데 필요한 세부 사항을 변경한 다음, 계층 수준에서 [edit] 명령을 복사하여 CLI에 붙여 넣은 다음, 구성 모드에서 들어갑니다 commit .
set security idp idp-policy idppolicy rulebase-ips rule 1 match from-zone any set security idp idp-policy idppolicy rulebase-ips rule 1 match source-address any set security idp idp-policy idppolicy rulebase-ips rule 1 match to-zone any set security idp idp-policy idppolicy rulebase-ips rule 1 match destination-address any set security idp idp-policy idppolicy rulebase-ips rule 1 match application default set security idp idp-policy idppolicy rulebase-ips rule 1 match attacks predefined-attack-groups “HTTP - All” set security idp idp-policy idppolicy rulebase-ips rule 1 then action close-client-and-server set security idp idp-policy idppolicy rulebase-ips rule 1 then notification log-attacks set security forwarding-options family inet6 mode flow-based set security policies from-zone trust to-zone untrust policy 1 match source-address any set security policies from-zone trust to-zone untrust policy 1 match destination-address any set security policies from-zone trust to-zone untrust policy 1 match application any set security policies from-zone trust to-zone untrust policy 1 then permit application-services idp-policy idppolicy set security policies from-zone untrust to-zone trust policy 1 match source-address any set security policies from-zone untrust to-zone trust policy 1 match destination-address any set security policies from-zone untrust to-zone trust policy 1 match application any set security policies from-zone untrust to-zone trust policy 1 then permit application-services idp-policy idppolicy set security zones security-zone untrust host-inbound-traffic system-services all set security zones security-zone untrust host-inbound-traffic protocols all set security zones security-zone untrust interfaces ge-0/0/0.0 set security zones security-zone untrust application-tracking set security zones security-zone trust host-inbound-traffic system-services all set security zones security-zone trust host-inbound-traffic protocols all set security zones security-zone trust interfaces ge-0/0/2.0 set interfaces ge-0/0/0 unit 0 family inet address 10.0.0.15/24 set interfaces ge-0/0/2 unit 0 family inet address 10.0.0.16/24
단계별 절차
다음 예에서는 구성 계층에서 다양한 수준을 탐색해야 합니다. 이를 수행하는 방법에 대한 지침은 CLI 사용자 가이드의 구성 모드에서 CLI 편집기 사용을 참조하십시오.
애플리케이션을 생성하고 이를 IDP 정책과 연결하려면
의미 있는 이름을 지정하여 정책을 만들고, 규칙 기준을 정책과 연결하고, 규칙 기준에 규칙을 추가하고, 규칙에 대한 일치 기준을 정의합니다.
[edit security] user@host#set idp idp-policy idppolicy rulebase-ips rule 1 match from-zone any user@host#set idp idp-policy idppolicy rulebase-ips rule 1 match source-address any user@host#set idp idp-policy idppolicy rulebase-ips rule 1 match to-zone any user@host#set idp idp-policy idppolicy rulebase-ips rule 1 match destination-address any user@host#set idp idp-policy idppolicy rulebase-ips rule 1 match application default user@host#set idp idp-policy idppolicy rulebase-ips rule 1 match attacks predefined-attack-groups “HTTP - All” user@host#set idp idp-policy idppolicy rulebase-ips rule 1 then action close-client-and-server user@host#set idp idp-policy idppolicy rulebase-ips rule 1 then notification log-attacks user@host#set forwarding-options family inet6 mode flow-based
정책을 구성합니다.
[edit security] user@host#set policies from-zone trust to-zone untrust policy 1 match source-address any user@host#set policies from-zone trust to-zone untrust policy 1 match destination-address any user@host#set policies from-zone trust to-zone untrust policy 1 match application any user@host#set policies from-zone trust to-zone untrust policy 1 then permit application-services idp-policy idppolicy user@host#set policies from-zone untrust to-zone trust policy 1 match source-address any user@host#set policies from-zone untrust to-zone trust policy 1 match destination-address any user@host#set policies from-zone untrust to-zone trust policy 1 match application any user@host#set policies from-zone untrust to-zone trust policy 1 then permit application-services idp-policy idppolicy
영역을 구성하고 인터페이스를 할당합니다.
[edit security] user@host# set zones security-zone untrust host-inbound-traffic system-services all user@host# set zones security-zone untrust host-inbound-traffic protocols all user@host# set zones security-zone untrust interfaces ge-0/0/0.0 user@host# set zones security-zone untrust application-tracking user@host# set zones security-zone trust host-inbound-traffic system-services all user@host# set zones security-zone trust host-inbound-traffic protocols all user@host# set zones security-zone trust interfaces ge-0/0/2.0
포워딩 인터페이스를 구성합니다.
[edit] user@host# set interfaces ge-0/0/0 unit 0 family inet address 10.0.0.15/24 user@host# set interfaces ge-0/0/2 unit 0 family inet address 10.0.0.16/24
결과
구성 모드에서 and show applications 명령을 입력 show security idp 하여 구성을 확인합니다. 출력에 의도한 구성이 표시되지 않으면 이 예의 구성 지침을 반복하여 수정합니다.
[edit]
user@host# show security idp
idp-policy idppolicy {
rulebase-ips {
rule 1 {
match {
from-zone any;
source-address any;
to-zone any;
destination-address any;
application default;
}
then {
action {
close-client-and-server;
}
notification {
log-attacks;
}
}
}
}
}
[edit]
user@host# show security policies
from-zone trust to-zone untrust {
policy 1 {
match {
source-address any;
destination-address any;
application any;
}
then {
permit {
application-services {
idp-policy idppolicy;
}
}
}
}
[edit]
user@host# show security zones
security-zone untrust {
host-inbound-traffic {
system-services {
all;
}
protocols {
all;
}
}
interfaces {
ge-0/0/0.0;
}
application-tracking;
}
[edit]
user@host# show interfaces
ge-0/0/0 {
unit 0 {
family inet {
address 10.0.0.15/24;
}
}
}
ge-0/0/2 {
unit 0 {
family inet {
address 10.0.0.16/24;
}
}
}
디바이스 구성이 완료되면 구성 모드에서 들어갑니다 commit .
검증
구성이 제대로 작동하는지 확인하려면 다음 작업을 수행하십시오.
구성 확인
목적
PCAP 피더 도구를 사용하여 PCAP를 실행한 후 IDP 공격 컨텍스트를 확인합니다.
작업
운영 모드에서 명령을 입력합니다.show security idp attack context
샘플 출력
user@host> show security idp attack context IDP context statistics: Context name #Hits #Data http-url 1 / http-get-url 1 / http-header-host 1 7.0.0.1 http-header-user-agent 1 lwp-request/5.827 libwww-perl/5.833 http-header 2 te: deflate,gzip;q=0.3 && connection: TE, close http-request 1 GET / HTTP/1.1 http-request-method 1 GET / HTTP/1.1
예: 투명 모드에서 패킷 캡처 피더 구성
이 예에서는 패킷 캡처(PCAP) 피더를 투명 모드로 실행하여 프로토콜 컨텍스트를 생성하는 방법을 설명합니다.
요구 사항
시작하기 전에:
네트워크 인터페이스를 구성합니다.
개요
관련 IDP 정책으로 PCAP 피더를 실행하여 패킷 캡처에서 실행 중인 패킷에서 관련 프로토콜 컨텍스트를 가져옵니다. 이 예에서 PCAP 피더 pcap-ip 2 7.0.0.1 는 패킷을 피딩하기 위해 자동 모드에서 사용됩니다.
구성
절차
CLI 빠른 구성
이 예를 빠르게 구성하려면, 아래 명령을 복사하여 텍스트 파일로 붙여 넣은 다음 모든 라인브레이크를 제거하고, 네트워크 구성을 일치하는 데 필요한 세부 사항을 변경한 다음, 계층 수준에서 [edit] 명령을 복사하여 CLI에 붙여 넣은 다음, 구성 모드에서 들어갑니다 commit .
set groups global protocols l2-learning global-mode transparent-bridge set security idp idp-policy idppolicy rulebase-ips rule 1 match from-zone any set security idp idp-policy idppolicy rulebase-ips rule 1 match source-address any set security idp idp-policy idppolicy rulebase-ips rule 1 match to-zone any set security idp idp-policy idppolicy rulebase-ips rule 1 match destination-address any set security idp idp-policy idppolicy rulebase-ips rule 1 match application default set security idp idp-policy idppolicy rulebase-ips rule 1 match attacks predefined-attack-groups “HTTP - All” set security idp idp-policy idppolicy rulebase-ips rule 1 then action close-client-and-server set security idp idp-policy idppolicy rulebase-ips rule 1 then notification log-attacks set security policies from-zone trust to-zone untrust policy 1 match source-address any set security policies from-zone trust to-zone untrust policy 1 match destination-address any set security policies from-zone trust to-zone untrust policy 1 match application any set security policies from-zone trust to-zone untrust policy 1 then permit application-services idp-policy idppolicy set security policies from-zone untrust to-zone trust policy 1 match source-address any set security policies from-zone untrust to-zone trust policy 1 match destination-address any set security policies from-zone untrust to-zone trust policy 1 match application any set security policies from-zone untrust to-zone trust policy 1 then permit application-services idp-policy idppolicy set security zones security-zone untrust host-inbound-traffic system-services all set security zones security-zone untrust host-inbound-traffic protocols all set security zones security-zone untrust interfaces ge-0/0/0.0 set security zones security-zone untrust application-tracking set security zones security-zone trust host-inbound-traffic system-services all set security zones security-zone trust host-inbound-traffic protocols all set security zones security-zone trust interfaces ge-0/0/2.0 set interfaces ge-0/0/0 unit 0 family ethernet-switching interface-mode access set interfaces ge-0/0/0 unit 0 family ethernet-switching vlan members 301 set interfaces ge-0/0/2 unit 0 family ethernet-switching interface-mode access set interfaces ge-0/0/2 unit 0 family ethernet-switching vlan members 301 set interfaces irb unit 301 family inet address 10.1.1.11/8 set vlans bd-vlan-301 vlan-id 301 set vlans bd-vlan-301 l3-interface irb.301
단계별 절차
다음 예에서는 구성 계층에서 다양한 수준을 탐색해야 합니다. 이를 수행하는 방법에 대한 지침은 CLI 사용자 가이드의 구성 모드에서 CLI 편집기 사용을 참조하십시오.
애플리케이션을 생성하고 이를 IDP 정책과 연결하려면
구성 그룹을 설정합니다.
[edit] user@host#set groups global protocols l2-learning global-mode transparent-bridge
의미 있는 이름을 지정하여 정책을 만들고, 규칙 기준을 정책과 연결하고, 규칙 기준에 규칙을 추가하고, 규칙에 대한 일치 기준을 정의합니다.
[edit security] user@host# set idp idp-policy idppolicy rulebase-ips rule 1 match from-zone any user@host# set idp idp-policy idppolicy rulebase-ips rule 1 match source-address any user@host# set idp idp-policy idppolicy rulebase-ips rule 1 match to-zone any user@host# set idp idp-policy idppolicy rulebase-ips rule 1 match destination-address any user@host# set idp idp-policy idppolicy rulebase-ips rule 1 match application default user@host# set idp idp-policy idppolicy rulebase-ips rule 1 match attacks predefined-attack-groups “HTTP - All” user@host# set idp idp-policy idppolicy rulebase-ips rule 1 then action close-client-and-server user@host# set idp idp-policy idppolicy rulebase-ips rule 1 then notification log-attacks user@host# set forwarding-options family inet6 mode flow-based
정책을 구성합니다.
[edit security] user@host# set policies from-zone trust to-zone untrust policy 1 match source-address any user@host# set policies from-zone trust to-zone untrust policy 1 match destination-address any user@host# set policies from-zone trust to-zone untrust policy 1 match application any user@host# set policies from-zone trust to-zone untrust policy 1 then permit application-services idp-policy idppolicy user@host# set policies from-zone untrust to-zone trust policy 1 match source-address any user@host# set policies from-zone untrust to-zone trust policy 1 match destination-address any user@host# set policies from-zone untrust to-zone trust policy 1 match application any user@host# set policies from-zone untrust to-zone trust policy 1 then permit application-services idp-policy idppolicy
영역을 구성하고 인터페이스를 할당합니다.
[edit security] user@host# set zones security-zone untrust host-inbound-traffic system-services all user@host# set zones security-zone untrust host-inbound-traffic protocols all user@host# set zones security-zone untrust interfaces ge-0/0/0.0 user@host# set zones security-zone untrust application-tracking user@host# set zones security-zone trust host-inbound-traffic system-services all user@host# set zones security-zone trust host-inbound-traffic protocols all user@host# set zones security-zone trust interfaces ge-0/0/2.0
포워딩 인터페이스를 구성합니다.
[edit] user@host# set interfaces ge-0/0/0 unit 0 family ethernet-switching interface-mode access user@host# set interfaces ge-0/0/0 unit 0 family ethernet-switching vlan members 301 user@host# set interfaces ge-0/0/2 unit 0 family ethernet-switching interface-mode access user@host# set interfaces ge-0/0/2 unit 0 family ethernet-switching vlan members 301 user@host# set interfaces irb unit 301 family inet address 10.1.1.11/8
VLAN-ID를 구성합니다.
[edit] user@host# set vlans bd-vlan-301 vlan-id 301 user@host# set vlans bd-vlan-301 l3-interface irb.301
결과
구성 모드에서 and show applications 명령을 입력 show security idp 하여 구성을 확인합니다. 출력에 의도한 구성이 표시되지 않으면 이 예의 구성 지침을 반복하여 수정합니다.
[edit]
user@host# show security idp
idp-policy idppolicy {
rulebase-ips {
rule 1 {
match {
from-zone any;
source-address any;
to-zone any;
destination-address any;
application default;
}
then {
action {
close-client-and-server;
}
notification {
log-attacks;
}
}
}
}
}
[edit]
user@host# show security policies
from-zone untrust to-zone trust {
policy 1 {
match {
source-address any;
destination-address any;
application any;
}
then {
permit {
application-services {
idp-policy idppolicy;
}
}
}
}
}
default-policy {
permit-all;
}
[edit]
user@host# show security zones
security-zone trust {
host-inbound-traffic {
system-services {
all;
}
protocols {
all;
}
}
interfaces {
ge-0/0/0.0;
ge-0/0/2.0;
}
advance-policy-based-routing-profile {
p1;
}
}
security-zone untrust {
host-inbound-traffic {
system-services {
all;
}
protocols {
all;
}
}
interfaces {
ge-0/0/1.0;
ge-0/0/2.0;
ge-0/0/3.0;
ge-0/0/0.0;
}
application-tracking;
}
[edit]
user@host# show interfaces
ge-0/0/0 {
unit 0 {
family inet {
address 14.0.0.1/24;
}
family ethernet-switching {
interface-mode access;
vlan {
members 301;
}
}
}
}
ge-0/0/2 {
unit 0 {
family inet {
address 192.0.3.1/24;
}
family ethernet-switching {
interface-mode access;
vlan {
members 301;
}
}
}
}
디바이스 구성이 완료되면 구성 모드에서 들어갑니다 commit .
검증
구성이 제대로 작동하는지 확인하려면 다음 작업을 수행하십시오.
구성 확인
목적
PCAP 피더 도구를 사용하여 PCAP를 실행한 후 IDP 공격 컨텍스트를 확인합니다.
작업
운영 모드에서 명령을 입력합니다.show security idp attack context
샘플 출력
user@host> show security idp attack context IDP context statistics: Context name #Hits #Data http-url 1 / http-get-url 1 / http-header-host 1 7.0.0.1 http-header-user-agent 1 lwp-request/5.827 libwww-perl/5.833 http-header 2 te: deflate,gzip;q=0.3 && connection: TE, close http-request 1 GET / HTTP/1.1 http-request-method 1 GET / HTTP/1.1
플랫폼별 패킷 캡처 동작
기능 탐색기를 사용하여 특정 기능에 대한 플랫폼 및 릴리스 지원을 확인하십시오.
다음 표를 사용하여 플랫폼의 플랫폼별 동작을 검토하십시오.
| 플랫폼 |
차이 |
|---|---|
| SRX 시리즈 방화벽 |
패킷 캡처를 지원하는 SRX300, SRX320, SRX340 및 SRX345 방화벽은 사용자가 현재 분석 상태를 보고 패킷 캡처 트래픽에 대해 이전에 처리된 데이터를 재설정할 수 있는 명령을 지원합니다 |