tcpreplay -VDisplays the version of tcpreplay installed and the compilation options used.
Replays captured pcap traffic onto a network at chosen speeds — useful for testing IDS rules and network devices.
sudo apt install tcpreplaytcpreplay --list-nicsLists available network interfaces and their capture methods to verify hardware visibility.
tcpreplay -i eth0 -t capture.pcapReplays traffic at 'topspeed', ignoring packet timing to send as fast as the hardware allows.
tcpreplay -i eth0 -x 2.0 capture.pcapReplays traffic at exactly 2.0 times the speed of the original capture speed.
tcpreplay -i eth0 -x 0.5 capture.pcapReplays traffic in slow motion at half the original capture speed.
tcpreplay -i eth0 -p 50 capture.pcapReplays traffic at a constant rate of 50 packets per second, overriding original timing.
tcpreplay -i eth0 -M 10.0 capture.pcapLimits the replay traffic throughput to 10.0 Megabits per second.
tcpreplay -i eth0 -l 0 capture.pcapReplays the capture file in an infinite loop until manually stopped.
tcpreplay -i eth0 --loop=5 capture.pcapReplays the capture file exactly 5 times and then exits.
tcpreplay -i eth0 -l 0 --loopdelay-ms=1000 capture.pcapLoops infinitely with a 1000 millisecond (1 second) pause between each iteration.
tcpreplay -i eth0 -L 100 capture.pcapStops the replay immediately after sending the first 100 packets.
tcpreplay -i eth0 --duration=10 capture.pcapLimits the total execution time to 10 seconds, regardless of how many packets are sent.
tcpreplay -i eth0 -q capture.pcapRuns in quiet mode, suppressing non-error output (useful for scripts).
tcpreplay -i eth0 --unique-ip capture.pcapModifies IP addresses per loop iteration to ensure each flow appears unique to network devices.
tcpreplay -i eth0 --unique-ip-loops=5 capture.pcapLoops traffic, modifying IP addresses to create unique flows for 5 iterations.
tcpreplay -i eth0 --unique-ip --netmap capture.pcapCombines unique IP generation with netmap detection for high-performance unique flow generation.
tcpreplay -i eth0 -I eth1 --cachefile=split.cache capture.pcapSplits traffic between two interfaces (client/server) based on a tcpprep cache file.
tcpreplay --intf1=eth0 --intf2=eth1 --cachefile=split.cache capture.pcapLong-form command to split traffic bi-directionally between eth0 and eth1 using a cache.
tcpreplay -i eth0 -1 capture.pcapSends one packet at a time, waiting for a user keypress before sending the next.
tcpreplay -i eth0 --timer=gtod capture.pcapUses the 'gettimeofday' system call for packet timing, which provides microsecond compatibility.
tcpreplay -i eth0 --timer=nano capture.pcapUses the 'nanosleep' API for high-precision packet timing delays.
tcpreplay -i eth0 --maxsleep=500 capture.pcapForces pauses between packets to never exceed 500 milliseconds, effectively compressing long idle gaps.
tcpreplay -i eth0 --sleep-accel=2 capture.pcapReduces the amount of time slept by 2 microseconds per packet to compensate for system latency.
tcpreplay -i eth0 -t -K --loop=0 capture.pcapStress tests an IDS by preloading the pcap and looping at maximum hardware speed.
tcpreplay -i eth0 -p 1 -l 0 capture.pcapSends a 'Low and Slow' attack simulation by sending only 1 packet per second continuously.
tcpreplay -i eth0 --unique-ip --mbps=500 capture.pcapSimulates a DDoS attack or botnet by generating high bandwidth traffic with constantly changing IP addresses.
tcpreplay -i eth0 -x 1.0 capture.pcapReplays an attack capture at exactly real-time speed to verify if the SIEM/IDS triggers correctly.
tcpreplay -i eth0 -M 1000.0 -l 60 capture.pcapLoads the link with 1Gbps of traffic for 60 loops to test throughput stability.
tcpreplay -i netmap:eth0 -t -K capture.pcapUses the netmap driver (if supported) for ultra-high-speed packet injection.
tcpreplay -i eth0 --verbose --decode="len=10" capture.pcapReplays with verbose output but passes arguments to the decoder to limit length.
tcpreplay -i eth0 --loop=100 --loopdelay-ms=10 capture.pcapRuns 100 loops with a very short 10ms gap between loops to maintain near-continuous pressure.
tcpreplay -i eth0 --mbps=0.1 capture.pcapReplays traffic at a very low rate of 100Kbps (0.1 Mbps) to test timeouts.
tcpreplay -i eth0 --pps=20000 capture.pcapInjects packets at a high rate of 20,000 packets per second regardless of packet size.
tcpreplay -i eth0 --timer=rdtsc capture.pcapUses the CPU cycle counter (RDTSC) for the highest possible timing precision on supported CPUs.
tcpreplay -i eth0 --limit=1 capture.pcapSends strictly the first packet of the capture file and then exits immediately.
tcpreplay -i eth0 --preload-pcap --quiet capture.pcapA high-performance script-friendly mode that preloads data and suppresses output.
tcpreplay -i eth0 --mbps=100 --loop=0 --unique-ip --stats=5 capture.pcapA complex scenario: infinite loop, unique IPs, 100Mbps limit, with stats printed every 5 seconds.
The classic packet capture tool: capture and filter traffic with BPF expressions and write it to pcap files for later analysis.
A high-performance, multi-threaded IDS/IPS and network security monitoring engine with EVE JSON logging.
A network intrusion detection and prevention system that inspects traffic in real time against a rule language.
A high-performance Linux networking toolkit using zero-copy packet mmap: capture, replay, traffic generation and analysis.
The utilities that ship with Wireshark — editcap, mergecap, capinfos, dumpcap and text2pcap — for working with capture files.