Opened 7 years ago

Closed 6 years ago

#11366 closed defect (fixed)

Hidden service cannot be created

Reported by: drazvan Owned by: n8fr8
Priority: Medium Milestone:
Component: Applications/Orbot Version:
Severity: Keywords: hidden service
Cc: Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

Hidden service creation and activation no longer works in the latest Orbot. Tested all the way up to 13.0.6 (nightly).

I've started a small HTTP server (KWS for Android) on port 8888 and set port 8888 in the "Hidden Services Ports" field and checked "Hidden Service Hosting". The hostname and private_key files are created (checked from root shell) but the service is not accessible.

Manually adding the service to app_bin/torrc and re-running tor makes the hidden service appear. I added this:

HiddenServiceDir /data/data/org.torproject.android/app_data/
HiddenServicePort 8888 127.0.0.1:8888

If I understand the Orbot sources correctly, the line it tries to add when enabling a service is

HiddenServicePort 8888 0.0.0.0:8888 (not sure if that makes a difference)

The ".Onion Hostname" field is _never_ populated, once again if I understand the sources correctly the getHiddenServiceHostname() private method in TorService is never called (in the latest version from Git).

Finally, when using the REQUEST_HS_PORT intent to trigger this externally, I get the dialog asking me to confirm the activation of the hidden service, then Orbot hangs altogether and must be force-killed.

I suspect this is due to the fact that the enableHiddenServicePort method in the Orbot class (https://gitweb.torproject.org/orbot.git/blob/HEAD:/src/org/torproject/android/Orbot.java#l357) is called from https://gitweb.torproject.org/orbot.git/blob/HEAD:/src/org/torproject/android/Orbot.java#l444 upon pressing the Accept button, on the UI thread, so the UI hangs while waiting for the hidden service to be created (and due to the defect above, it never returns).

Child Tickets

Change History (5)

comment:1 in reply to:  description Changed 7 years ago by arma

Replying to drazvan:

HiddenServicePort 8888 0.0.0.0:8888 (not sure if that makes a difference)

This line tells Tor that when connections come in to the hidden service on (virtual) port 8888, Tor should make a tcp connection to an outgoing destination 0.0.0.0:8888.

That might work, depending on how the interfaces are set up on the machine, but you probably want 127.0.0.1 or some other more common word for 'localhost'.

comment:2 Changed 6 years ago by drazvan

Any updates on this? It looks like the Hidden Service settings are completely useless, even in the latest version (as installed from Google Play Store). Hidden Services still cannot be activated from Orbot as far as I can tell.

comment:3 Changed 6 years ago by n8fr8

Sorry haven't had time to look at it yet, but will make sure it is fixed in v14 (in alpha now)

comment:5 Changed 6 years ago by n8fr8

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.