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

configurable-http-proxy

Package Overview
Dependencies
Maintainers
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

configurable-http-proxy

A python implementation of configurable-http-proxy

  • 0.3.0
  • PyPI
  • Socket score

Maintainers
2

configurable-http-proxy

This is a pure python implementation of the configurable-http-proxy written in nodejs. It is meant to be a drop in replacement.

Install

Prerequisite: Python 3.6+

pip install configurable-http-proxy

Feature support

The following items are supported:

  • Proxying for Websocket and HTTP requests
  • Configuring the proxy using API requests
  • Auth token for API requests
  • Error management using error_path and error_target
  • Prepend path or include prefix
  • Timeouts
  • X-Forward related headers
  • Custom Headers
  • Customizable storage backends
  • PID file writing
  • Logging
  • Configurable storage backend

The following options are additional (not available in nodejs CHP currently):

  • Ready to use DBMS storage backend

The following options are not supported (yet):

  • SSL for proxy, client, API is not available (--ssl-*, --api-ssl-*, --client-ssl-*, --insecure)
  • Redirecting: --redirect-port and --redirect-to
  • Change Origin: --change-origin
  • Rewrites in Location header: --protocol-rewrite and --auto-rewrite
  • Metrics server: --metrics-port and --metrics-ip

Database-backed storage backend

Using a SQL DBMS instead of the default in-memory store enables chp to be replicated in a High Availability scenario.

To use a SQL DBMS as the storage backend:

  1. Install DBMS support
$ pip install configurable-http-proxy[sqla]
  1. Set the CHP_DATABASE_URL env var to any db URL supported by SQLAlchemy. The default is sqlite:///chp.sqlite.
$ export CHP_DATABASE_URL="sqlite:///chp.sqlite"
$ configurable-http-proxy --storage-backend configurable_http_proxy.dbstore.DatabaseStore
  1. Optionally you may set the table name by setting the CHP_DATABASE_TABLE. The default is 'chp_routes'
$ export CHP_DATABASE_TABLE="chp_routes"

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