Skip to main content

Device Proxy. A reverse HTTP Proxy that can inspect and manipulate HTTP Headers before sending upstream.

Project description

Inspects incoming HTTP requests adds some HTTP headers and proxies upstream. Has ability to add extra cookies for HTTP responses being sent back to the client.

travis coveralls

Installation

$ pip install device-proxy

Running

Run with twistd:

$ twistd -n devproxy --config config.yaml

Configuration

This is what the processing chain looks like:

       +------------------+
       |                  |
       |           Header & Cookie set
       v                  |
(1) HAProxy -> (2) *n* DeviceProxies
       |
      (3)
       | (if Cookie or Header set)
       +--------------------------------> (4) *n* Backend Apps
  1. Haproxy receives incoming traffic from Nginx

  2. Request is passed to n number of Device Proxies running. HTTP headers are inserted (possibly from cached WURFL or OpenDDR lookups). Device Proxy has the option of inserting Cookies into the HTTP response which can cache the Device Lookup (for subsequent requests HAProxy (1) could use these cookie values to skip DeviceProxy completely for the lifetime of the Cookie.) DeviceProxy reverse proxies back to HAProxy with HTTP headers inserted.

  3. HAProxy inspects the HTTP headers & cookies received and selects appropriate backend application for the request. HAProxy can have a default fallback backend. If the Cookie is already set then the DeviceProxies are skipped.

  4. The Backend application renders the request with a template set suitable for the given HTTP request.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

device-proxy-0.4.1.tar.gz (17.2 kB view details)

Uploaded Source

Built Distribution

device_proxy-0.4.1-py2.7.egg (56.3 kB view details)

Uploaded Source

File details

Details for the file device-proxy-0.4.1.tar.gz.

File metadata

File hashes

Hashes for device-proxy-0.4.1.tar.gz
Algorithm Hash digest
SHA256 6979dfb85e08f92c571403904853b1dd6d86aade20dc2e79915fbfc3ab225916
MD5 3a2bbb03aea9a1768cdbb081faf7ecee
BLAKE2b-256 006cc8aa179742d6ed1d3c1db48073dc43e95a6ac0eaa97f08ba570079f3e07a

See more details on using hashes here.

File details

Details for the file device_proxy-0.4.1-py2.7.egg.

File metadata

File hashes

Hashes for device_proxy-0.4.1-py2.7.egg
Algorithm Hash digest
SHA256 5cc9b923bd234ef4a737c8d4402b23d1b48f4fff52b79a6d259870e0b508bec0
MD5 b1f973f370033c30a32a017898e4222d
BLAKE2b-256 907ee497168094a4513023880e2fd507d3a74717fdeb656ed71aba1cdc7f1c9e

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page