aboutsummaryrefslogtreecommitdiffstats
path: root/mitmproxy/master.py
diff options
context:
space:
mode:
authorThomas Kriechbaumer <thomas@kriechbaumer.name>2017-12-18 19:51:29 +0100
committerThomas Kriechbaumer <thomas@kriechbaumer.name>2017-12-18 19:51:29 +0100
commit05a8559dff7a04d8c4109f98357321031c0981f9 (patch)
tree36187c6ba32f7dc4f0cfdf50754ea347bfae6ee9 /mitmproxy/master.py
parent417a860f322769961dfae470aa065df4457162e1 (diff)
downloadmitmproxy-05a8559dff7a04d8c4109f98357321031c0981f9.tar.gz
mitmproxy-05a8559dff7a04d8c4109f98357321031c0981f9.tar.bz2
mitmproxy-05a8559dff7a04d8c4109f98357321031c0981f9.zip
add doc string
Diffstat (limited to 'mitmproxy/master.py')
-rw-r--r--mitmproxy/master.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/mitmproxy/master.py b/mitmproxy/master.py
index 9660c137..de3b24e1 100644
--- a/mitmproxy/master.py
+++ b/mitmproxy/master.py
@@ -120,6 +120,11 @@ class Master:
self.addons.trigger("done")
def _change_reverse_host(self, f):
+ """
+ When we load flows in reverse proxy mode, we adjust the target host to
+ the reverse proxy destination for all flows we load. This makes it very
+ easy to replay saved flows against a different host.
+ """
if self.options.mode.startswith("reverse:"):
_, upstream_spec = server_spec.parse_with_mode(self.options.mode)
f.request.host, f.request.port = upstream_spec.address