Skip to content

ljianhui/NetworkSniffer

Repository files navigation

This is a network sniffer program, such as tcpdump.

Program name: netsniffer

Development environment:
	linux 2.6.32 + g++ 4.4.7 + raw socket 


Class view:
	Analysis
	   |
	   |------EthernetAnalysis
	   |
	   |------ArpAnalysis
	   |
	   |------IpAnalysis
	   |
	   |------TcpAnalysis
	   |
	   |------UdpAnalysis
	   |
	   |------IcmpAnalysis

	RowSocket
	AnaylsisTree

Protocol Analysis tree:

	EthernetAnalysis
		/\
	       /  \
	      /	   \
	     /	    \
	    /	     \
       ArpAnalysis  IpAnalysis
			/|\
		       / | \
		      /  |  \
		     /   |   \
		    /    |    \
		   /     |     \
		  /      |      \
		 /       |       \
		/        |        \
       IcmpAnalysis TcpAnalysis  UdpAnalysis  

Core design thinking:
	Composite patterns
		
help:
	-i(interface) : the name of network interface, such as -i eth0, catch the packet of eth0

	-p(protocol) : set protocol filter, such as -p tcp, view the tcp packet

	-g(Gui) : use the gui view, ps: the app ./netsniffer and ./NetSnifferGui must in the same dir

About

This is a network sniffer program, such as tcpdump.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published