This code implements a simple sniffer that listens for any type of packet and prints the raw data in hexadecimal format.
[Download file simplesniffer.c]
Simple ARP Sniffer.
This code implements a sniffer that listens for ARP packets and prints ARP headers to stdout.
[Download file arpsniffer.c]
This implements a bit more advanced tool that listens for TCP packets with the ACK or PSH-ACK flags set, crafts a valid TCP RST packet for the connection and sends it through a raw socket. This should result in a denial of service for the host computer and possibly for other hosts in the same network segment.
[Download file tcpsyndos.c]