Opened 3 years ago

Last modified 3 years ago

#20795 needs_information defect

Torbrowser crashes if it can't DNS resolve the Socks5Proxy host in torrc

Reported by: gaffer206 Owned by: tbb-team
Priority: Medium Milestone:
Component: Applications/Tor Browser Version:
Severity: Normal Keywords: tbb-usability
Cc: mcs, brade Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

Using Torbrowser 6.0.6 on OS X Yosemite.

When in the office behind our corporate firewall I configure Torbrowser to use our socks5 proxy.

When at home Torbrowser crashes on launch.

If I delete the Sock5Proxy line from torrc it works.

If I put a dummy entry for my office socks proxy host in /etc/hosts torbrowser doesn't crash.

Tor should trap a failed DNS resolve when validating the proxy config on launch and tell the user that it can't connect to the internet.

Child Tickets

Change History (7)

comment:1 Changed 3 years ago by cypherpunks

Component: - Select a componentCore Tor/Tor

comment:2 Changed 3 years ago by dgoulet

Component: Core Tor/TorApplications/Tor Browser
Owner: set to tbb-team

comment:3 Changed 3 years ago by gk

Status: newneeds_information

Hm. What happens if you use Tor Browser's own means for configuring your proxy? You can do that on the launcher wizard (instead of connecting directly you need to choose the configure option). And later on if you don't have a proxy available you can remove that option on the wizard again as it is otherwise not connecting.

comment:4 Changed 3 years ago by gaffer206

I am using Tor Browser's own means for configuring the proxy. When I'm at home I can't get to the wizard as Tor crashes before this step.

Here is a screen recording. It starts connected to my corporate network via VPN. I launch Torbrowser, configure it to use the socks proxy and use Torbrowser to search for Tor using DuckDuckGo.

Then I quit Torbrowser and drop the VPN and relaunch Torbrowser.

Torbrowser crashes before it is possible to change the proxy setting.

https://drive.google.com/file/d/0BwhuUU2g0GM9RGs1enY2ZUlhdUU/view?usp=sharing

Last edited 3 years ago by gaffer206 (previous) (diff)

comment:5 Changed 3 years ago by gaffer206

i can fix the problem as follows:

sed -i -e '/Socks5Proxy/d' ./Library/Application\ Support/TorBrowser-Data/Tor/torrc

comment:6 Changed 3 years ago by gk

Cc: mcs brade added
Keywords: tbb-usability added

Thanks for the screen recording! I wonder if it would work for you if you clicked on "Open Settings" after you disabled your VPN and restarted Tor Browser but before the Tor related error message came up?

mcs, brade: I wonder why the "Reconfigure" option is not shown on the wizard after the first error message. Wasn't #11773 for that scenario as well?

comment:7 in reply to:  6 Changed 3 years ago by mcs

Replying to gk:

Thanks for the screen recording! I wonder if it would work for you if you clicked on "Open Settings" after you disabled your VPN and restarted Tor Browser but before the Tor related error message came up?

I am not sure that will be possible. At least for me, tor exits immediately during startup because the proxy host cannot be resolved:

DATE [warn] Failed to parse/validate config: Socks5Proxy failed to parse or resolve. Please fix.

In the screen recording, it seemed to take a while though; I guess it depends on how fast the DNS lookup is for the unknown host (it might have to timeout if the DNS servers are unreachable).

mcs, brade: I wonder why the "Reconfigure" option is not shown on the wizard after the first error message. Wasn't #11773 for that scenario as well?

I don't think this scenario was covered. The problem is that "Reconfigure" is only possible if tor is running. Tor Launcher could include a "Delete existing configuration" checkbox (or a second restart button) on that "Restart Tor" wizard screen. If that option was chosen, Tor Launcher would zero out the torrc file before trying to start tor.

The best solution might be to use a separate browser profile when connected to the corporate network (I know that might be inconvenient).

Note: See TracTickets for help on using tickets.