GET requests in TOR network without installing TOR browser/bundle?

五迷三道 提交于 2020-01-03 00:55:30

问题


I want to perform http/https GET requests to the TOR network.

My one issue is that this project needs to be scaleable, the software I'm designing needs to be light so having all users installing the TOR bundle to use with my program isn't possible.

Is there someway to generate GET requests on the TOR network without having the browser? For example can I do direct requests to a TOR bridge?


回答1:


Yes, it's possible. Tor Browser just runs the Tor daemon in the background and proxies it's requests through it. You'll just want to install, configure, and run the daemon yourself for your application.

For Windows download and install the Tor expert bundle. On Linux, either compile the latest version from source, or install one of their repositories to your system and install via the package manager (recommended). Note: Your current distro probably has Tor available as a package but you shouldn't use that because they are typically not kept up to date and are running much older versions. Use one of the repositories managed by the Tor project as those releases are kept up to date.

You'll then need to edit the torrc configuration file if you wish to make changes or customize the SocksPort (the port your application will use to proxy requests and DNS lookups through Tor) and other settings.

You'll then probably want to refer to the manual and since you mentioned you're using Python, look into using Stem to communicate with Tor using its control protocol. Stem also has some functionality for launching Tor processes as well. Then depending on what networking/HTTP library you're using in your application, see if it supports SOCKS5 and configure it to use Tor's SOCKS port for communication.



来源:https://stackoverflow.com/questions/38847434/get-requests-in-tor-network-without-installing-tor-browser-bundle

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!