Tor Project
A Pi a day, keeps censorship away
You would like to support human rights? Then please follow the how-to.
Note: We assume you have a new working Arch Linux running on your RaspberryPi.
Installation
First we have to install all the packages which are needed & useful to us.
<sxh bash;> root@pi# pacman -Syyu root@pi# pacman -S base-devel vim tor ntp tor vnstat sudo </sxh>
After that we should create us an own user account with sudo privileges.
<sxh bash;> root@pi# useradd -m -s /bin/bash YOUR_USERNAME root@pi# vimsudo /etc/sudoers … </sxh>
Now, we install yaourt in order to fetch and install packages from the AUR.
<sxh bash;> root@pi# su YOUR_USERNAME root@pi# wget https://aur.archlinux.org/packages/ya/yaourt/yaourt.tar.gz root@pi# tar xfv yaourt.tar.gz root@pi# cd yaourt root@pi# makepkg -si root@pi# cd ~/ root@pi# rm -r yaourt* root@pi# yaourt -Syua root@pi# yaourt -S arm </sxh>
In order to integrate tor into systemd, we need to write a -n own service file, which ensures fast, easy usage and the guarantuee that at every boot tor will be started along.
<sxh bash;> root@pi# cd /etc/systemd/system root@pi# vim tor.service </sxh>
<sxh bash; title: systemd service file - /etc/systemd/system/tor.service> [Unit] Description=Starting Tor Service
[Service] ExecStart=/usr/bin/tor -f /etc/tor/torrc
[Install] After=multi-user.target </sxh>
<sxh bash;> root@pi# vim ntp-once.service </sxh>
<sxh plain; title:>
</sxh>
Configuration
After this, we finally attack the most important part: Tor configuration.
<sxh bash;> root@pi# cd /etc/tor/ root@pi# mv torrc torrc.original root@pi# vim torrc </sxh>
<sxh plain; title: /etc/tor/torrc> ORPort 443
Log notice file /var/log/tor/notices.log
RelayBandwidthRate 100 KB # Throttle traffic to 100KB/s (800Kbps) RelayBandwidthBurst 200 KB # But allow bursts up to 200KB/s (1600Kbps)
#AccountingStart day 00:00 #AccountingMax 8 GB
SocksPort 0 BridgeRelay 1 Exitpolicy reject *:* </sxh>
Up & Run!
Either type:
<sxh bash;> root@pi# systemctl start tor </sxh>
or simply boot up your device.