Click here to Skip to main content
11,922,589 members (29,375 online)
Click here to Skip to main content
Add your own
alternative version


114 bookmarked

Network Sniffer

, 19 Jul 2004 CPOL
Rate this:
Please Sign up or sign in to vote.
Network Sniffer

Sample Image - Sniffer.jpg


A "Packet Sniffer" is a utility that sniffs without modifying the network's packets in any way. By comparison, a firewall sees all of a computer's packet traffic as well, but it has the ability to block and drop any packets that its programming dictates. Packet sniffers merely watch, display, and log this traffic.

One disturbingly powerful aspect of packet sniffers is their ability to place the hosting machine's network adapter into "promiscuous mode." Network adapters running in promiscuous mode receive not only the data directed to the machine hosting the sniffing software, but also ALL of the traffic on the physically connected local network.

I hope that this piece of code will help you understand the network better.


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Eran Aharonovich
Software Developer
Australia Australia
Been a programmer since 1999.
Experience in:
.Net, C++, C#, VB, VB.NET, ASP, ASP.NET, DLLs, COM etc.

You may also be interested in...

Comments and Discussions

QuestionWe can catch the TCP packet only? Pin
MD8414-May-07 22:57
memberMD8414-May-07 22:57 
AnswerRe: We can catch the TCP packet only? Pin
Eran Aharonovich14-May-07 23:03
memberEran Aharonovich14-May-07 23:03 
GeneralRe: We can catch the TCP packet only? Pin
priyanka,oberoi110-Aug-09 2:37
memberpriyanka,oberoi110-Aug-09 2:37 
Generalgetting IP address Pin
AYcoder7-Aug-06 10:08
memberAYcoder7-Aug-06 10:08 
QuestionOutbound traffic is not catched Pin
John Ashraf24-Jul-06 13:22
memberJohn Ashraf24-Jul-06 13:22 
Generalrunning the network sniffer Pin
ujal13-Jul-06 8:18
memberujal13-Jul-06 8:18 
GeneralRe: running the network sniffer Pin
Eran Aharonovich13-Jul-06 8:27
memberEran Aharonovich13-Jul-06 8:27 
GeneralRe: running the network sniffer Pin
ujal14-Jul-06 6:33
memberujal14-Jul-06 6:33 
i did with borland c++ compiler do i need visual c++...

do u have idea to converts packets's data in readable form...i am trying it with java...and got the result in hexadecimal form and so on..

Generaldisplay number of packets Pin
dReAmWoNderS5-Jul-06 5:48
memberdReAmWoNderS5-Jul-06 5:48 
QuestionMore fragments problem Pin
Wouter Dhondt18-Jun-06 6:06
memberWouter Dhondt18-Jun-06 6:06 
GeneralXP SP2 Problem Pin
jopus22-Jul-05 12:31
memberjopus22-Jul-05 12:31 
GeneralI Get Inbound traffic only Pin
jopus28-Apr-05 21:23
memberjopus28-Apr-05 21:23 
GeneralPlease help me! Pin
dSolariuM29-Mar-05 5:45
memberdSolariuM29-Mar-05 5:45 
GeneralRe: Please help me! Pin
Eran Aharonovich30-Mar-05 7:32
memberEran Aharonovich30-Mar-05 7:32 
QuestionAnd the environment is? Pin
abica1-Mar-05 5:42
memberabica1-Mar-05 5:42 
AnswerRe: And the environment is? Pin
Eran Aharonovich25-Jul-05 2:07
memberEran Aharonovich25-Jul-05 2:07 
QuestionHow top begin writing a packet sniffer? Pin
grace4raghu227-Dec-04 5:42
membergrace4raghu227-Dec-04 5:42 
GeneralFeeto Pin
feeto27-Dec-04 4:46
sussfeeto27-Dec-04 4:46 
GeneralRe: Feeto Pin
Anonymous27-Dec-04 5:45
sussAnonymous27-Dec-04 5:45 
GeneralHi Pin
Sanjit Rath1-Nov-04 5:21
memberSanjit Rath1-Nov-04 5:21 
GeneralRe: Hi Pin
Eran Aharonovich25-Jul-05 2:22
memberEran Aharonovich25-Jul-05 2:22 
GeneralThe article Location Pin
sergeyv20028-Sep-04 11:26
membersergeyv20028-Sep-04 11:26 
GeneralRe: The article Location Pin
Eran Aharonovich30-Mar-05 7:33
memberEran Aharonovich30-Mar-05 7:33 
GeneralNice sniffer.. but.. Pin
Michael Hendrickx21-Aug-04 4:49
memberMichael Hendrickx21-Aug-04 4:49 
GeneralRe: Nice sniffer.. but.. Pin
Eran Aharonovich21-Aug-04 8:43
memberEran Aharonovich21-Aug-04 8:43 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Terms of Use | Mobile
Web04 | 2.8.151125.1 | Last Updated 20 Jul 2004
Article Copyright 2004 by Eran Aharonovich
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid