aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAmmonite <pierre@ambox.fr>2017-01-30 23:41:47 +0100
committerAmmonite <pierre@ambox.fr>2017-01-30 23:41:47 +0100
commitaaff9dfd32ec32e98000b66c4ee9f3e328ab0c91 (patch)
treececab6e248e6eed57941867634711ec7f4565cd4
parentc2c6050df398ecb922cf040ea7c5c3ab8cdeac03 (diff)
downloadmitmproxy-aaff9dfd32ec32e98000b66c4ee9f3e328ab0c91.tar.gz
mitmproxy-aaff9dfd32ec32e98000b66c4ee9f3e328ab0c91.tar.bz2
mitmproxy-aaff9dfd32ec32e98000b66c4ee9f3e328ab0c91.zip
Reset the host header to the correct destination
-rw-r--r--examples/complex/dns_spoofing.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/examples/complex/dns_spoofing.py b/examples/complex/dns_spoofing.py
index 5e6cf978..1fb59f74 100644
--- a/examples/complex/dns_spoofing.py
+++ b/examples/complex/dns_spoofing.py
@@ -53,6 +53,7 @@ class Rerouter:
if m.group("port"):
port = int(m.group("port"))
+ flow.request.headers["Host"] = host_header
flow.request.host = sni or host_header
flow.request.port = port