A lightweight TCP/UDP echo client and server written in Python.
Originally built as a real-world troubleshooting tool to verify network reachability and confirm that traffic was not being blocked or dropped between systems.
It’s ideal for testing firewall rules, NAT configurations, routing, or general connectivity between hosts — especially when tools like ping or nc aren’t enough.
This project started as a practical solution for diagnosing complex networking issues.
When you need to verify if traffic truly passes through every hop — or confirm whether a specific port/protocol works end-to-end — this echo tool gives a quick, reliable answer.
It’s simple, self-contained, and runs anywhere Python is available.
- Supports both TCP and UDP protocols
- Acts as either server (receiver) or client (sender)
- Fully interactive for manual testing
- Works without external dependencies
- Graceful shutdown with
Ctrl + C - Prints clear connection and message logs
- Python 3.6+
- No external packages required (uses only
socketandargparse)
Run in either receiver or sender mode:
# Start TCP receiver
python3 echotool.py -r -t tcp -b 0.0.0.0 -p 55555
# Start UDP receiver
python3 echotool.py -r -t udp -b 0.0.0.0 -p 55555
# Send TCP message
python3 echotool.py -s -t tcp -b 10.0.0.50 -p 55555
# Send UDP message
python3 echotool.py -s -t udp -b 10.0.0.50 -p 55555