deja-packet

deja-packet - Version 1.0 - June 26th, 2007

Written by Vanya A. Sergeev - vsergeev at gmail


Download the latest deja-packet source here: deja-packet-1.0.tar.gz

Download a gziped x86 linux binary of deja-packet here: deja-packet-linux-x86-1.0.gz


deja-packet transmits raw packets through a specified interface.

Usage: ./deja-packet -pcap <libpcap capture file> <interface name>
   or: ./deja-packet -raw <raw packet file> <interface name>

Note: you must be root to successfully transmit packets with deja-packet due to the Linux security restrictions with raw sockets. A packet sniffer like Wireshark can be used for further tracking/analysis of the transmitted packet.

deja-packet is basically a simple debugging tool that retransmits packets you may later want to observe as they traverse the network (watching them get routed, bridged, etc.).

In the [-p]cap mode, deja-packet transmits selected packets from a libpcap capture file (such as one created by Ethereal/Wireshark, or tcpdump). In the [-r]aw mode, deja-packet transmits the raw contents of a file as one whole packet.

The [-p]cap mode is interactive: the user will be continuously prompted to select which packet from the libpcap capture file to transmit, until the “q” character is encountered, where the program will quit.

Example pcap mode:

$ sudo ./deja-packet -p icmp_ping.pcap eth0
Select packet number (1 to 6) for transmission or q for quit: 1
Successfully transmitted packet!
Select packet number (1 to 6) for transmission or q for quit: 2
Successfully transmitted packet!
Select packet number (1 to 6) for transmission or q for quit: 5
Successfully transmitted packet!
Select packet number (1 to 6) for transmission or q for quit: 6
Successfully transmitted packet!
Select packet number (1 to 6) for transmission or q for quit: q
$

In the [-r]aw mode, deja-packet exits immediately after the attempted transmission is complete (allows deja-packet to be easily used with a script).

Example raw mode:

$ sudo ./deja-packet -r samplepacket eth0
Successfully transmitted packet!
$

icmp_ping.pcap is included as a sample libpcap capture file. To compile deja-packet, simply use the command “make”. deja-packet remains Linux-only because it requires PF_PACKET sockets.

deja-packet is released under the GNU General Public License version 2.

Please notify me of any bugs or suggestions at vsergeev at gmail.

 
Back to top
software_projects/deja-packet.txt · Last modified: 2007/12/04 23:50 by vsergeev
[Driven by DokuWiki] [Recent changes RSS feed] [Valid XHTML 1.0] [dokuwiki 'simple' template by chi]