Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

HiddenRequest

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

HiddenRequest

A tool that builds on both requests and Torrequests to include a VPN and randomized headers

  • 0.0.4
  • PyPI
  • Socket score

Maintainers
1

HiddenRequest

A tool to combine TorRequest, an extension of Python Software Foundation's Requests, RandomHeaders, and ProtonVPN with some useful processes to hide traffic.

Install

pip install hiddenrequest

Dependencies

Tor and ProtonVPN installed on your local machine.

Setup

Tor via homebrew:

brew install tor

For linux use the debian repo Tor. Once installed, edit /etc/tor/torrc and uncomment the line ControlPort 9051 to allow your application to control tor.

ProtonVPN CLI via directions here: ProtonVPNOnce installed, follow the setup steps for protonvpn init.

Next, open your sudo file to allow you to run ProtonVPN passwordless:

sudo visudo

Below %sudo ALL=(ALL:ALL) ALL add "username ALL=(ALL) NOPASSWD:/usr/local/bin/protonvpn", replacing username with your own username.

Usage

import HiddenRequest
with HiddenRequest() as hr:
	r = hr.get('https://www.google.com')
	

Hidden Request automatically configures your VPN and will verify that your traffic is hidden. You can verify no IP or DNS leakage yourself using:

bool = HiddenRequest().verify_hidden()

Includes randomized headers using RandomHeaders.

with HiddenRequest() as hr:
	my_header_data = {"Content-Type":"image.jpeg"}
	my_header_data.append(hr.random_header)
	r = hr.get('https://www.google.com', headers = my_header_data)
	

HiddenRequest also inherits TorRequest methods like reset_identity.

	with HiddenRequest() as hr:
			# Your own machines IP that you want to hide
			original_data = hr.original_ip_data
			# Your new IP from a Tor relay
			first_data = hr.public_ip_data
			hr.reset_identity()
			# Another Tor relay IP
			new_data = hr.public_ip_data

Testing

pytest --pyargs HiddenRequest	
	

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc