Tor: Difference between revisions

From Alpine Linux
No edit summary
m (Reverting due Cat template not working for some reason, sorry the mess.)
Line 17: Line 17:
If Tor connections are blocked in your country, use {{Pkg|lyrebird}} package for a transparent proxy solution. To allow your tor daemon to use <code>lyrebird</code>, add the following line to your tor config file {{Path|/etc/tor/torrc}} as follows:{{Cat|/etc/tor/torrc|...
If Tor connections are blocked in your country, use {{Pkg|lyrebird}} package for a transparent proxy solution. To allow your tor daemon to use <code>lyrebird</code>, add the following line to your tor config file {{Path|/etc/tor/torrc}} as follows:{{Cat|/etc/tor/torrc|...
ClientTransportPlugin obfs4 exec /usr/bin/lyrebird}}
ClientTransportPlugin obfs4 exec /usr/bin/lyrebird}}
In particular countries such as Russia this might not work. In this case, access Tor network via bridge. First get bridges either from official [https://t.me/GetBridgesBot Telegram bot] or request bridges from settings of Tor Browser installed on another machine. Then append to {{Path|/etc/tor/torrc}} bridge connection arguments:{{Cat|/etc/tor/torrc|...
Bridge obfs4 12.34.56.78:90 FINGERPRINTALLCAPS123 cert=verylongcert iat-mode=0
UseBridges 1}}


For config changes in {{Path|/etc/tor/torrc}} to take effect (re)start the tor daemon: {{Cmd|# rc-service tor restart}}
For config changes in {{Path|/etc/tor/torrc}} to take effect (re)start the tor daemon: {{Cmd|# rc-service tor restart}}

Revision as of 17:59, 31 March 2025

The Onion Routing (Tor) project, aims to have a way to use the internet with as much privacy as possible, and the idea was to route traffic through multiple servers and encrypt it each step of the way.

Installation

The Tor daemon can be installed using the tor package. Use OpenRC to manage the tor service.

Note: The official Tor browser can only be installed using Flatpak.

Configuration

Tor service

Tor reads its configurations from the file /etc/tor/torrc by default, or if the latter is not found, from $HOME/.torrc. A example configuration with documentation is in the file /etc/tor/torrc.sample. Logs are written to /var/log/tor/notices.log by default.

The default configuration should work fine for most Tor users.

If Tor connections are blocked in your country, use lyrebird package for a transparent proxy solution. To allow your tor daemon to use lyrebird, add the following line to your tor config file /etc/tor/torrc as follows:

Contents of /etc/tor/torrc

... ClientTransportPlugin obfs4 exec /usr/bin/lyrebird

For config changes in /etc/tor/torrc to take effect (re)start the tor daemon:

# rc-service tor restart

Firefox browser

To use the Tor service running on the local host, configure Firefox browser as follows:

  • In Preferences > General > Network Settings > Settings... , select Manual proxy configuration.
  • Enter SOCKS host localhost with port 9050 (SOCKS v5).

Tractor

The Tractor tool available as tractor package can be used to control the Tor daemon using the versatile GSettings for a personalized TOR experience. The GUI front-end Carburetor for Tractor is also available as carburetor package.

See also