Ngrep: Difference between revisions

From 탱이의 잡동사니
Jump to navigation Jump to search
(Created page with "== Overview == 리눅스 명령어 ngrep 사용 정리. == Basic == ngrep 은 일종의 tcpdump 와 비슷한 개념의 명령어이다. == Options == === -q === Quiet 옵...")
 
No edit summary
Line 37: Line 37:
* http://cidog.com/bbsDetail.abc?bwoId=7604&&page=21&category=56&refine=true - ngrep 다운로드 및 사용법
* http://cidog.com/bbsDetail.abc?bwoId=7604&&page=21&category=56&refine=true - ngrep 다운로드 및 사용법


[[category:linux]]
[[category:command]]

Revision as of 13:20, 28 August 2015

Overview

리눅스 명령어 ngrep 사용 정리.

Basic

ngrep 은 일종의 tcpdump 와 비슷한 개념의 명령어이다.

Options

-q

Quiet 옵션. 패킷 헤더와 페이로드를 제외한 다른 내용은 표시하지 않는다.

-v

Invert. 매칭되는 패킷은 제외하고 표시한다.

-t/-T

Timestamp 를 표시한다. -t 옵션은 패킷이 도착한 시간을 표시하고, -T 옵션은 패킷간의 간격을 시간으로 표시한다.

host

source/destination 모두에 입력한 주소값을 매칭시킨다.

dst host : destination 에만 주소값을 매칭시킨다. src host : source 에만 주소값을 매칭시킨다.

Examples

pchero@mywork:~$ sudo ngrep -qt host 10.1.27.62
interface: eth0 (10.1.27.0/255.255.255.0)
filter: (ip or ip6) and ( host 10.1.27.62 )

T 2015/08/28 13:05:48.617855 173.252.102.16:443 -> 10.1.27.62:57349 [AP]
  ....CL.Z.F.D.(......\E.Ys.%..Nj.O.?I.-.l..wQi..d= '.........@d.0.p..!l..

See also