Today I've implemented a simple IP Packet Sniffer.
Sometimes is useful to know what're the IP packages that transit on your network, for Analyze network problems, Monitor network usage, Debug client/server communications or Debug network protocol implementations.
The tool is very simple, but I think that can be useful to learn something more about IP and TCP packets and Protocols implementation.
Maybe you can extend this Tool to support other Transport Layer Protocol.
Note: You need to run it as Root.
You can find the Source Code Here: IP Packet Sniffer Source Code.