4

On my linux box, I have both Tor and Tor browser bundle installed and running.

I was wondering which of those two is to be preferred (in the sense of being the most robust to potential "anonymity leaks", the fastest, and the "most logical"):

torsocks curl http://example.com

or

curl --socks5 127.0.0.1:9150 http://example.com

3 Answers 3

3

You should use either

torsocks curl http://example.com

or

curl --socks5-hostname 127.0.0.1:9150 http://example.com

to ensure that DNS requests aren't leaked.

3
  • 1
    The question is asking which of those two is preferred. Listing them out again doesn't really answer the question asked. Commented Jun 26, 2014 at 0:26
  • This answer is misleading. It should be deleted, I think, because fixing it would make it duplicate the other answer. Yes?
    – mirimir
    Commented Jun 27, 2014 at 1:45
  • @AndrewLott Note that --socks5-hostname is very different than --socks5. Commented May 10, 2020 at 16:05
2

You should definitely use torsocks curl here, because curl --socks5 does NOT use the given SOCKS proxy to resolve DNS name. See torsocks documentation for more specifics. Also, you can use usewithtor [application] instead of torsocks [application].

1

ONLY curl --socks5-hostname 127.0.0.1:9150 http://example.com because to not-leak-dns you must not doing DNS queries =) and --socks5-hostname clause forces NOT using resolvers at all, and passing the raw hostname to the proxy to resolve. Forget 'torificators' if a program/library supports total avoiding DNS queries.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .