Skip to main content

What

This script allows you to initialize multiple TOR instances and proxy to them using an API.

The script automatically refreshes TOR IP's after a number of calls through each TOR Socket.

Running

To get started with Torman:

  • Install with pip: $ pip install torman
  • Then Start: $ torman

You should see the following output.

,---------.    ,-----.    .-------.    ,---.    ,---.   ____    ,---.   .--. 
\          \ .'  .-,  '.  |  _ _   \   |    \  /    | .'  __ `. |    \  |  | 
 `--.  ,---'/ ,-.|  \ _ \ | ( ' )  |   |  ,  \/  ,  |/   '  \  \|  ,  \ |  | 
    |   \  ;  \  '_ /  | :|(_ o _) /   |  |\_   /|  ||___|  /  ||  |\_ \|  | 
    :_ _:  |  _`,/ \ _/  || (_,_).' __ |  _( )_/ |  |   _.-`   ||  _( )_\  | 
    (_I_)  : (  '\_/ \   ;|  |\ \  |  || (_ o _) |  |.'   _    || (_ o _)  | 
   (_(=)_)  \ `"/  \  ) / |  | \ `'   /|  (_,_)  |  ||  _( )_  ||  (_,_)\  | 
    (_I_)    '. \_/``".'  |  |  \    / |  |      |  |\ (_ o _) /|  |    |  | 
    '---'      '-----'    ''-'   `'-'  '--'      '--' '.(_,_).' '--'    '--' 
    ┌                                   ┐
    │  Manage TOR Proxies like a Boss!  │
    └                                   ┘

2021-12-11 21:13:48 mugendis-beast Torman[53081] INFO Started 4 TOR instances.
2021-12-11 21:13:48 mugendis-beast waitress[53081] INFO Serving on http://0.0.0.0:6930
30

This confirms that Torman is ready and runnibng on the default port 6930. Torman is now ready to start taking your requests and you can run the following CURL command.

curl --request GET \
  --url http://127.0.0.1:6930/ \
  --header 'Content-Type: application/json' \
  --data '{"url" : "https://ipinfo.tw/ip"}'

This should return a response showing your current TOR IP address.

{
  "meta": {
    "proxy": {
      "port": 9060,
      "remaining-requests": 49
    },
    "took": "367ms"
  },
  "response": "185.220.101.170"
}

This shows the proxy port used, remaining-requests till the IP refreshes, the response as well as how long it took to get the response. Repeat the CURL command and note that the TOR proxies keep getting rotated with each proxy call.

API

You can pass arguments to fine tune how torman works.

torman --help will show you all the available commands.

  • --refresh-after Number of requests after which the TOR IP gets refreshed. You must provide a control passwoerd for this to work. Defaults to 50 requests.
  • --control-pass Your TOR control password. Used to renew TOR IPs when refresh-after value has been reached.
  • --server The port through which Torman listens for REST API requests. Default is 6930
  • --instances Number of TOR instances to initiate. Default is 4. Torman will cycle through the TOR instances and allocate requests to each.
  • --stop Stop Torman and all TOR instances.
  • --verbose Show/Log API requests

Examples

  1. torman --verbose
  2. torman --refresh-after 10 --control-pass my_pass refresh after 10 TOR requests wusing "my_pass" as the control password

Beware!

  1. Stopping Torman using the --stop argument stops all running TOR and Torman instances. This includes any TOR processes not initiated by Torman. You might need to manually restart them, if any. That said, why would you be running TOR processes manually when you have Torman?

Logo created by DesignEvo logo maker

Metadata

Release files for torman 0.0.6

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for torman 0.0.6
File Size Uploaded Provenance Actions
torman-0.0.6.tar.gz 10.4 kB Without provenance Details for torman-0.0.6.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for torman 0.0.6
File Interpreter ABI Platform Actions
torman-0.0.6-py3-none-any.whl Python 3 none any Details for torman-0.0.6-py3-none-any.whl

Total release size: 26.1 kB

Release files / torman-0.0.6.tar.gz

Download URL torman-0.0.6.tar.gz
Size 10.4 kB
Tags Source
SHA-256 checksum
How to use checksums
cad3f8c961b627159daffe124bb2249949522a83d970ec6e94874d7d36cabfb3
BLAKE2b-256 checksum
How to use checksums
cfc7ad1c37a0e62c7af0652dce65cead2db1d57be1606cb3427ab904176657e4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/3.10.1 pkginfo/1.8.2 requests/2.22.0 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.8.10

Release files / torman-0.0.6-py3-none-any.whl

Download URL torman-0.0.6-py3-none-any.whl
Size 15.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
25b76153640767c6f8104a3400783baba7caf3f3f6e42055d32024c19ebd006d
BLAKE2b-256 checksum
How to use checksums
ec42af69909ffc44cee454dd18d4918e9008c76b6c3bcf28225222bba60a7157
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/3.10.1 pkginfo/1.8.2 requests/2.22.0 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.8.10

Security for torman 0.0.6

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page