I am trying to write a script where I make a connection through Tor in Python. I can currently connect to Tor and request a new ip NEWNYM but I seem to get stuck at sending data. The data never gets received.
and the connection is never made by Tor to the resultant address.
No connection is ever made… I have tried numerous things for about 5 days now. I would appreciate any help anyone can provide
*cheers
I highly recommend SocksiPy. It is extremely easy to use, and once you’ve established a connection it works just like a regular TCP socket. Here is a brief sample from their SourceForge page:
I have used it in several large projects with no problems. It may not be exactly what you are looking for if you will regularly need to interact directly with the SOCKS5 server (and even then, it will probably be able to do what you need), but in the vast majority of cases SocksiPy is more than sufficient.