blob: d319276a580cfc77387ed12402829d44bac32b67 [file] [log] [blame] [view]
Andrew Top61a84952019-04-30 15:07:33 -07001proxy.py
2========
3
4Lightweight HTTP, HTTPS and WebSockets Proxy Server in Python.
5
6Features
7--------
8
9- Distributed as a single file module
10- No external dependency other than standard Python library
11- Support for `http`, `https` and `websockets` request proxy
12- Optimize for large file uploads and downloads
13- IPv4 and IPv6 support
14- Basic authentication support
15
16Install
17-------
18
19To install proxy.py, simply:
20
21 $ pip install proxy.py
22
23Usage
24-----
25
26```
27$ proxy.py -h
28usage: proxy.py [-h] [--hostname HOSTNAME] [--port PORT] [--backlog BACKLOG]
29 [--basic-auth BASIC_AUTH]
30 [--server-recvbuf-size SERVER_RECVBUF_SIZE]
31 [--client-recvbuf-size CLIENT_RECVBUF_SIZE]
32 [--log-level LOG_LEVEL]
33
34proxy.py v0.3
35
36optional arguments:
37 -h, --help show this help message and exit
38 --hostname HOSTNAME Default: 127.0.0.1
39 --port PORT Default: 8899
40 --backlog BACKLOG Default: 100. Maximum number of pending connections to
41 proxy server
42 --basic-auth BASIC_AUTH
43 Default: No authentication. Specify colon separated
44 user:password to enable basic authentication.
45 --server-recvbuf-size SERVER_RECVBUF_SIZE
46 Default: 8 KB. Maximum amount of data received from
47 the server in a single recv() operation. Bump this
48 value for faster downloads at the expense of increased
49 RAM.
50 --client-recvbuf-size CLIENT_RECVBUF_SIZE
51 Default: 8 KB. Maximum amount of data received from
52 the client in a single recv() operation. Bump this
53 value for faster uploads at the expense of increased
54 RAM.
55 --log-level LOG_LEVEL
56 DEBUG, INFO (default), WARNING, ERROR, CRITICAL
57 --host_resolver Default: No host resolution. JSON hosts file used for
58 hostname IP resolution.
59
60Having difficulty using proxy.py? Report at:
61https://github.com/abhinavsingh/proxy.py/issues/new
62```