From 1af26bb915789d51264a3410e016dfea90fe60b9 Mon Sep 17 00:00:00 2001 From: Aldo Cortesi Date: Tue, 21 Feb 2012 12:32:56 +1300 Subject: Minor docs and example script fixes. --- README.mkd | 4 ++-- doc-src/reverseproxy.html | 8 ++++++++ doc-src/screenshots/mitmproxy.png | Bin 175466 -> 71881 bytes examples/flowbasic | 4 ++-- examples/stickycookies | 4 ++-- libmproxy/proxy.py | 1 - 6 files changed, 14 insertions(+), 7 deletions(-) diff --git a/README.mkd b/README.mkd index 4c2af2da..94405ab7 100644 --- a/README.mkd +++ b/README.mkd @@ -3,7 +3,7 @@ console interface that allows traffic flows to be inspected and edited on the fly. __mitmdump__ is the command-line version of mitmproxy, with the same -functionality but without the frills. Think tcpdump for HTTP. +functionality but without the user interface. Think tcpdump for HTTP. Both tools are fully documentented in the commandline _--help_ flag, and, in the case of __mitmproxy__, a built-in help page accessible through the _?_ @@ -17,7 +17,7 @@ Features - Save complete HTTP conversations for later replay and analysis. - Replay the client-side of an HTTP conversations. - Replay HTTP responses of a previously recorded server. -- Reverse proxy mode to forward traffic to a specified server +- Reverse proxy mode to forward traffic to a specified server. - Make scripted changes to HTTP traffic using Python. - SSL certificates for interception are generated on the fly. diff --git a/doc-src/reverseproxy.html b/doc-src/reverseproxy.html index e69de29b..125be19a 100644 --- a/doc-src/reverseproxy.html +++ b/doc-src/reverseproxy.html @@ -0,0 +1,8 @@ + +- command-line: _-R_ http[s]://hostname[:port] +- mitmproxy shortcut: _R_ + +In reverse proxy mode, mitmproxy acts as a standard HTTP server and forwards +all requests to the specified upstream server. Note that the displayed URL for +flows in this mode will use the value of the __Host__ header field from the +request, not the reverse proxy server. diff --git a/doc-src/screenshots/mitmproxy.png b/doc-src/screenshots/mitmproxy.png index 1766167e..4dad7728 100644 Binary files a/doc-src/screenshots/mitmproxy.png and b/doc-src/screenshots/mitmproxy.png differ diff --git a/examples/flowbasic b/examples/flowbasic index d3981329..b419f9e7 100755 --- a/examples/flowbasic +++ b/examples/flowbasic @@ -30,10 +30,10 @@ class MyMaster(flow.FlowMaster): return f -ssl_config = proxy.SSLConfig( +config = proxy.ProxyConfig( cacert = os.path.expanduser("~/.mitmproxy/mitmproxy-ca.pem") ) state = flow.State() -server = proxy.ProxyServer(ssl_config, 8080) +server = proxy.ProxyServer(config, 8080) m = MyMaster(server, state) m.run() diff --git a/examples/stickycookies b/examples/stickycookies index b290f2fd..88bf0063 100755 --- a/examples/stickycookies +++ b/examples/stickycookies @@ -34,9 +34,9 @@ class StickyMaster(controller.Master): msg._ack() -ssl_config = proxy.SSLConfig( +config = proxy.ProxyConfig( cacert = os.path.expanduser("~/.mitmproxy/mitmproxy-ca.pem") ) -server = proxy.ProxyServer(ssl_config, 8080) +server = proxy.ProxyServer(config, 8080) m = StickyMaster(server) m.run() diff --git a/libmproxy/proxy.py b/libmproxy/proxy.py index 8e0aa9cd..583e533b 100644 --- a/libmproxy/proxy.py +++ b/libmproxy/proxy.py @@ -30,7 +30,6 @@ class ProxyConfig: self.reverse_proxy = reverse_proxy - def read_headers(fp): """ Read a set of headers from a file pointer. Stop once a blank line -- cgit v1.2.3