1

I'm trying to set up requests over Tor, while rotating over IPs.

I've found this answer explaining everything quite clear. I've set it up and am able to request via Tor. That is, via one single IP.

To allow for rotation, I need to uncomment some lines in a file named torrc, as described in the answer. However, this file does not exist on my computer.

I've checked tor.stackoverflow and found this answer, however its there neither. I posed a question on tor.stackoverflow, but the only comment I got so far hasn't helped. It also seems tor.stackoverflow isn't that active.

I hope someone here had the same issue and is able to help me. I'm working on Mac OS X Sierra 10.12.3.

Community
  • 1
  • 1
LucSpan
  • 1,831
  • 6
  • 31
  • 66

1 Answers1

0

I am the author of the answer in your question.

The torrc sample should be located at /opt/local/etc/tor/torrc.sample as per the documentation and you can copy that to some other place and start tor using the copied torrc.

tor -f </path/to/torrc> [args]

In case you do not find the sample torrc, you can get one from the official svn source.

If you want to find out what your currently running tor instance is using as it's torrc, I checked the running processes on my system (ps -ef | grep tor for Ubuntu) and found the following

debian-+  1373     1  0 09:30 ?        00:00:16 /usr/bin/tor --defaults-torrc /usr/share/tor/tor-service-defaults-torrc -f /etc/tor/torrc --RunAsDaemon 0

Maybe you can do something similar on your system and if lucky, get the -f argument and thus the default torrc location.

shad0w_wa1k3r
  • 12,955
  • 8
  • 67
  • 90
  • Thank you for your help. So far I've managed to copy the `torrc.sample`, edit it and save it as `torrc`. I've tried the `tor -f [args]` in Terminal, but I'm not sure it worked. I did `tor -f [args]`, i.e. I did not change `[args]`, is that ok? – LucSpan Mar 21 '17 at 12:44
  • You can drop the `[args]` part entirely unless you know what you are doing. – shad0w_wa1k3r Mar 21 '17 at 12:49
  • `tor -f [args]` gives `No such file or directory`. However, the torrc file is there and my path is correct. `tor -f ` gives `syntax error near unexpected token newline`. `tor -f [args]` gives a new prompt. I'm lost. – LucSpan Mar 21 '17 at 12:56
  • Let's take this to the [python chat room](https://chat.stackoverflow.com/rooms/6/python) where you can give me your torrc to look at. – shad0w_wa1k3r Mar 21 '17 at 13:27
  • Ok, I'm in the room now. – LucSpan Mar 21 '17 at 13:33