Stealth Chat is a secure chat application that uses simple ROT encryption to obfuscate messages and hides communication within ICMP packets. This project uses a combination of Python, Bash, and third-party tools to ensure both secure and stealth communication between clients and servers.
- Stealth communication: Hides chat messages in ICMP packets.
- Encryption: Uses a simple ROT cipher to encrypt messages.
- Cross-platform: Supports both Linux and Windows with the help of ptunnel.
- Port forwarding: Ensures secure communication through port forwarding.
- Bash and Python scripts: Automates setup and connection handling.
.
├── README.md
├── include
│ ├── client-connect.sh
│ ├── line-formatter.sh
│ ├── messenger.sh
│ └── server-connect.sh
├── main-chat.sh
├── pf-lin.py
└── pf-win.py
For the sake of simplicity, this project has been modified to chat on loopback address instead of two machines. Users have to run this software within their respective OS, no need to chat inter-OSs. Route the traffic through ports such that, the data gets encrypted, burried in packets and then decrypted approriately.
- ptunnel-ng: A tool to setup ICMP tunnel on WSL
- ptunnel: A tool to setup ICMP tunnel on MAC (ng version is not available on homebrew)
- Python 3: Required for port forwarding.
- ncat: Netcat tool that comes with nmap
Clone and build ptunnel-ng from the following repository:
git clone https://github.com/utoni/ptunnel-ng.git
cd ptunnel-ng
chmod +x autogen.sh
./autogen.sh
make install
OR
curl http://ports.ubuntu.com/pool/universe/p/ptunnel-ng/ptunnel-ng_1.42-1_arm64.deb -o ptunnel-ng.deb
sudo dpkg -i ptunnel-ng.deb
brew install ptunnel
On WSL
sudo ptunnel-ng
On MAC OS
sudo ptunnel
On WSL
sudo ptunnel-ng -p127.0.0.1 -l6666 -R5555
On Mac OS
sudo ptunnel -p 127.0.0.1 -lp 6666 -dp 5555 -c lo0
Start port forwarder 2
python3 pf-lin.py
Start port forwarder 1
python3 pf-win.py
Run the main Bash script to start the chat server
chmod +x main-chat.sh
./main-chat.sh
Use ncat
to connect to the chat server through the secure tunnel:
ncat 127.0.0.1 4444