Zeronet: How to connect ZeroNet to the Tor Network?

Created on 5 Jan 2016  ·  21Comments  ·  Source: HelloZeroNet/ZeroNet

I started the Tor Browser, restarted ZeroNet and nothing happened. There is just the text "TOR: Waiting". How can I connect to the Tor Network introduced in version 0.3.5 (r830)? Maybe the issue is already posted here.

Most helpful comment

Tor by default running on ports 9050/9051. if you want to use it with Tor browser's tor instance you have start zeronet using --tor_proxy 127.0.0.1:9150 --tor_controller 127.0.0.1:9151

All 21 comments

Read the FAQ, followed the instructions but the same thing happened.

What OS are you using?

Ubuntu GNOME 15.10

please try the instructions in #229, it helped there

Okay, thanks for helping.

I'm looking for similar instructions for OSX + Tor Browser.

I've tried several things but can't find what to do.

in tools/tor/torrc I'm trying with:

ControlPort 9151
SOCKSPort 9150
CookieAuthentication 0

TorBrowser seems to be using SOCKS5 on :9150.

I also have success with:

echo 'PROTOCOLINFO' | nc 127.0.0.1 9151
250-PROTOCOLINFO 1
250-AUTH METHODS=COOKIE,SAFECOOKIE,HASHEDPASSWORD COOKIEFILE="/opt/homebrew-cask/Caskroom/torbrowser/4.5.3/TorBrowser.app/TorBrowser/Data/Tor/control_auth_cookie"
250-VERSION Tor="0.2.7.6"
250 OK

But whatever I try I get
TorManager Tor controller connect error: error: [Errno 61] Connection refused in TorManager.py line 154 > socket.py line 344

Tor by default running on ports 9050/9051. if you want to use it with Tor browser's tor instance you have start zeronet using --tor_proxy 127.0.0.1:9150 --tor_controller 127.0.0.1:9151

It works! But then, what's the torrc file for?

On windows tor is automatically downloaded on first startup that that's the configuration file for it. it's not used on other platforms

OK so it's a documentation issue. Here's some text that could be added to
“Frequently asked questions - ZeroNet” just after the Linux block:
http://zeronet.readthedocs.org/en/latest/faq/#how-to-use-zeronet-with-tor

### How to make ZeroNet work with Tor Browser under OS X?

Install TorBrowser.app; it exposes ports 9150 (SOCKS proxy) and 9151
(Control Port).
Launch `python start.py --tor always --tor_proxy 127.0.0.1:9150
--tor_controller 127.0.0.1:9151`

Allow TorBrower to connect to localhost: Settings > Advanced > Configure how Tor Browser connects to the Internet > Add 127.0.0.1 in “No proxy for”

It's not recommended to use the Tor browser's tor instance, because if you close the browser zeronet will also loose the connection. Running tor as system service is better: https://www.torproject.org/docs/tor-doc-osx.html.en

  1. I understand. Not sure I fully agree, I like the idea to have zeronet connect through TorBrowser: it makes things easier to install and understand (is it on, is it off? You can see it immediately).
  2. Currently the zeronet docs leads to Tor official install page, which in turn recommends TorBrowser in bold face on the first line of https://www.torproject.org/docs/tor-doc-osx.html.en

Now, here's what happens when I quit TorBrowser.app and browse to a site that isn't available locally:

[15:39:22] TorManager Tor addOnion error:
[15:39:22] - Unhandled exception
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/site-packages/gevent/greenlet.py", line 327, in run
    result = self._run(*self.args, **self.kwargs)
  File "plugins/AnnounceZero/AnnounceZeroPlugin.py", line 69, in announceTracker
    onion = self.connection_server.tor_manager.getOnion(site.address)
  File "/Users/fil/Source/zeronet/ZeroNet/src/Tor/TorManager.py", line 256, in getOnion
    self.site_onions[site_address] = self.addOnion()
  File "/Users/fil/Source/zeronet/ZeroNet/src/Tor/TorManager.py", line 197, in addOnion
    res = self.request("ADD_ONION NEW:RSA1024 port=%s" % self.fileserver_port)
  File "/Users/fil/Source/zeronet/ZeroNet/src/Tor/TorManager.py", line 229, in request
    return self.send(cmd)
  File "/Users/fil/Source/zeronet/ZeroNet/src/Tor/TorManager.py", line 235, in send
    conn.send("%s\r\n" % cmd)
  File "/usr/local/lib/python2.7/site-packages/gevent/socket.py", line 437, in send
    return sock.send(data, flags)
error: [Errno 32] Broken pipe

If you often leaves and re-joins the network, then it is bad for you: You client has to re-validate the contents by ask updates to all site you have visited before and it's also results lots of unreliable/unreachable peers which is bad for the network.

I don't quit TorBrowser.app very often, it was just for testing :)

When it comes to online/offline connectivity, I guess it's the same problem with tor as a service.

For windows there is an "expert bundle" that contains tor.exe, so we can download/configure/start it automatically, it would be nice to have same way for mac, but i have not found binary tor.app distribution yet

Mac OS is a Unix based system, so the Linux binaries should work with Mac, I guess.

No, they not working, but there is no binary for Linux neither

Or you can use proxifier, and set your proxy to 127.0.0.1:9150

@HelloZeroNet This issue is resolved -- can we close it?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

mkg20001 picture mkg20001  ·  3Comments

blurHY picture blurHY  ·  3Comments

DaniellMesquita picture DaniellMesquita  ·  3Comments

imachug picture imachug  ·  3Comments

jerry-wolf picture jerry-wolf  ·  4Comments