0

I'm currently using the NEWNYM signal to programmatically replicate the functionality of changing Tor circuits. However, it seems that this doesn't always function as intended and for certain sites retains the same circuit, which does not happen when I click the 'New Tor Circuit For This Site' button.

Do I need to perform any additional functionality apart from sending the NEWNYM Signal, to replicate the behavior of the 'New Tor Circuit For This Site' button?

0

The NEWNYM signal doesn't change circuits for existing connections, it only marks existing circuits as "dirty", which makes them unusable for new connections. So in addition to sending a NEWNYM signal, you probably want to also close all existing connections.

I think that Tor Browser itself doesn't use the NEWNYM signal, but instead uses stream isolation features of tor. For example, by using a different SOCKS password, tor will use a different circuit for that connection.

Tor Browser may do other things as well, but I'm not sure. For example the Tor Browser design document mentions you should also not reuse existing "HTTP Keep-Alive" connections. (See "Tor circuit and HTTP connection linkability" in https://2019.www.torproject.org/projects/torbrowser/design/)

1
  • Thanks for the info @Steve. What's the easiest way that I can close the connection for an existing website? Will some form of page refresh do the trick? To add some context, I'm trying to perform this through Selenium but I'm fine with sending Tor control commands if necessary. – numX Feb 15 at 5:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.