Torlock - a simple script to prevent outgoing packets from bypassing Tor.

Kyle Williams kyle.kwilliams at
Mon Mar 1 16:38:49 UTC 2010

You might want to look at JanusVM.

On Mar 1, 2010 7:05 AM, "Irratar" <irratar77 at> wrote:


I have created a simple Bash script to prevent any data from bypassing Tor
when Tor is running. I started it to use just for myself, but now I think
it will be better to share it with other users of Tor.

This script, named Torlock, does the following things when used to start
- Creates a special user named torlock by default (if you run it first time
 or have removed that user after previous Tor session).
- Uses Iptables to block network access for everyone except for torlock.
- Setuids to torlock and starts Tor. Tor will be started in background mode,
 and its output redirected to a file.

When used to stop Tor, it stops Tor, unlocks network access, and
removes torlock user.

More information is in included text file. Even more can be obtained by
the script. It is small, simple, and easy to make sure it's not
backdoored. The script can be downloaded from Sourceforge:

Inspite of its simplicity, Torlock saved me at least twice when I forgot to
switch Torbutton on.

With best regards,
To unsubscribe, send an e-mail to majordomo at with
unsubscribe or-talk    in the body.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the tor-talk mailing list