mirror of
https://github.com/Start9Labs/documentation.git
synced 2026-03-26 02:11:55 +00:00
120 lines
3.9 KiB
ReStructuredText
120 lines
3.9 KiB
ReStructuredText
.. _tor-mac:
|
|
|
|
==================
|
|
Running Tor on Mac
|
|
==================
|
|
|
|
Install Homebrew
|
|
----------------
|
|
|
|
#. If you do not have Homebrew installed, follow the installation instructions `here <https://brew.sh/>`_. TLDR: Open the Terminal and paste the following line:
|
|
|
|
.. code-block:: bash
|
|
|
|
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
|
|
|
|
#. You will be prompted for your system password before installation; proceed with entering your password. You may be asked more than once.
|
|
|
|
#. You will be notified which directories Homebrew is going to create, hit :code:`RETURN`:
|
|
|
|
.. figure:: /_static/images/tor/install_homebrew1.png
|
|
:width: 80%
|
|
:alt: Homebrew installation
|
|
|
|
Homebrew creates the directories and downloads any other files it needs e.g. “Command Line Tool for Xcode” and “Homebrew”.
|
|
|
|
Wait a few minutes while it downloads and installs what it needs.
|
|
|
|
Once installation is complete, close the Terminal.
|
|
|
|
.. warning:: Surprisingly, Homebrew uses Google Analytics to collect anonymous usage data. You can deselect the option to share usage data by `opting out <https://docs.brew.sh/Analytics#opting-out>`_.
|
|
|
|
Install Tor
|
|
-----------
|
|
|
|
.. caution:: If you have the Tor Browser open, close it and quit the application.
|
|
|
|
.. note:: If you are on a very old version of macOS, such as High Sierra (10.13) or below, first execute this command in a Terminal window:
|
|
|
|
.. code-block::
|
|
|
|
echo 'export PATH="/usr/local/bin:$PATH"' >> ~/.bash_profile
|
|
|
|
Then close the Terminal.
|
|
|
|
#. Open a new Terminal and install Tor using the following command:
|
|
|
|
.. code-block:: bash
|
|
|
|
brew install tor
|
|
|
|
|
|
#. Then run Tor with:
|
|
|
|
.. code-block:: bash
|
|
|
|
brew services start tor
|
|
|
|
This will start Tor and ensure that it is always running, even after a restart. See the `Tor Project docs <https://2019.www.torproject.org/docs/tor-doc-osx.html.en>`_ for more details.
|
|
|
|
Enable Tor System-wide
|
|
----------------------
|
|
|
|
|
|
#. Enable proxy autoconfig file (This will download the Start9 standard proxy config file. You can use your own if you prefer):
|
|
|
|
.. code-block:: bash
|
|
|
|
sudo curl https://start9.com/assets/proxy.pac --output /Library/WebServer/Documents/proxy.pac
|
|
|
|
#. Now enable apache service:
|
|
|
|
.. code-block:: bash
|
|
|
|
sudo launchctl enable system/org.apache.httpd
|
|
sudo launchctl kickstart system/org.apache.httpd
|
|
|
|
.. note:: If these commands fail, your version of macOS may still use the older launchctl syntax:
|
|
|
|
.. code-block:: bash
|
|
|
|
sudo launchctl load -w /System/Library/LaunchDaemons/org.apache.httpd.plist
|
|
|
|
#. Go to System Settings:
|
|
|
|
.. figure:: /_static/images/tor/systemSettings.png
|
|
:width: 40%
|
|
:alt: System Preferences
|
|
|
|
#. Click on *Network* and then select the interface on which you wish to enable Tor system-wide (both Ethernet and WiFi advised - do one then the other):
|
|
|
|
.. figure:: /_static/images/tor/ventura-settings.png
|
|
:width: 80%
|
|
:alt: Select Network
|
|
|
|
#. Click *Details*:
|
|
|
|
.. figure:: /_static/images/tor/ventura-network-advanced.png
|
|
:width: 80%
|
|
:alt: Click Advanced
|
|
|
|
#. Click "Proxies," then select "Automatic Proxy Configuration," add this URL: ``http://localhost/proxy.pac``, then click "OK":
|
|
|
|
.. figure:: /_static/images/tor/ventura-proxies-corrected.png
|
|
:width: 80%
|
|
:alt: Select Proxys
|
|
|
|
Done! You have now enabled system-wide Tor potential.
|
|
|
|
We advise going back to step 4 and repeating this for Wifi/Ethernet depending on which interface you haven't done yet.
|
|
|
|
If you ever need to view the status of the tor service, enter the following into a Terminal:
|
|
|
|
.. code-block:: bash
|
|
|
|
cat /usr/local/var/log/tor.log || sudo cat /opt/homebrew/var/log/tor.log
|
|
|
|
If using Firefox
|
|
----------------
|
|
Firefox can be configured to use Tor on your Mac to resolve .onion URLs. Complete this guide: :ref:`tor-ff`
|