Skip to content

Python Requests and Stem helper for making HTTP requests over Tor.

License

Notifications You must be signed in to change notification settings

Ian-Costa18/stemquests

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

stemquests

Python Requests and Stem helper for making HTTP requests over Tor.

Purpose

A Tor proxy and the Python requests package are difficult to work with. This package attempts to fix this issue by creating a module (TorInstance) that allows starting new Tor proxy processes using stem, then generating requests Sessions to send requests with.

Usage

Simply import TorInstance, create the object, then call tor.get_session() to get a new requests session!

from stemquests import TorInstance

tor = TorInstance()
session = tor.get_session()

print(session.get('https://check.torproject.org').text)

TODO

  • Create a "cycling" proxy that sets up a set number of Tor connections then uses the next in the chain when it is needed.
  • Create a simple function to verify Tor's connection using checktor.torproject.org.

About

Python Requests and Stem helper for making HTTP requests over Tor.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages