Spoiler Proxy — Network fault simulator

Redirect all traffic from your application to Spoiler Proxy

Your application for testing must be started with proxychains. This utility redirects all the traffic through SOCKS5 proxy. In configuration file specify where SpoilerProxy is running. In this example it is localhost at port 1080.

Install proxychains

Ubuntu:

sudo apt install -y git make gcc
git clone https://github.com/rofl0r/proxychains-ng.git
cd proxychains-ng
make
sudo make install
cd ..
rm -rf proxychains-ng

CentOs:

sudo yum install -y git make gcc
git clone https://github.com/rofl0r/proxychains-ng.git
cd proxychains-ng
make
sudo make install
cd ..
rm -rf proxychains-ng

Note: You can skip sudo make install step if you do not have a root access rights.

Configure proxychains4

Create file $HOME/.proxychains/proxychains.conf with content:

strict_chain
proxy_dns
tcp_read_time_out 150000
tcp_connect_time_out 80000
[ProxyList]
socks5 127.0.0.1 1080


Change the last line with the location where Spoiler Proxy is installed.

Test everything

Then start your application for testing:

proxychains4 <your app>

Examples

Simulate HTTPS connection to google:

proxychains4 telnet www.google.com 443

Check all connections which Firefox actually does. Try it:)

proxychains4 firefox

Finally test your application:

proxychains4 java -jar my-super-app.jar

You can use Spoiler Proxy with your Android Application too.

After running your test application with proxychains go to spoiler proxy management console (http://localhost:8484) and try to spoil some connection.