aboutsummaryrefslogtreecommitdiffstats
path: root/examples/flowbasic
diff options
context:
space:
mode:
authorMaximilian Hils <git@maximilianhils.com>2015-09-04 00:47:04 +0200
committerMaximilian Hils <git@maximilianhils.com>2015-09-04 00:47:04 +0200
commite88c7e4c58a862d6a222d1f8d4638102228b929e (patch)
treea801f9bc87ff8f6a7e0cedc37ab57c2edc69cb4a /examples/flowbasic
parent2d1c382f38d3b1cf9219ddb9b62ef196a4381976 (diff)
parentee8e5947df4af80d85d255d087f94a5f98722ef0 (diff)
downloadmitmproxy-e88c7e4c58a862d6a222d1f8d4638102228b929e.tar.gz
mitmproxy-e88c7e4c58a862d6a222d1f8d4638102228b929e.tar.bz2
mitmproxy-e88c7e4c58a862d6a222d1f8d4638102228b929e.zip
Merge branch 'master' into readthedocs
Diffstat (limited to 'examples/flowbasic')
-rwxr-xr-xexamples/flowbasic7
1 files changed, 3 insertions, 4 deletions
diff --git a/examples/flowbasic b/examples/flowbasic
index 6663dc46..78b9eff7 100755
--- a/examples/flowbasic
+++ b/examples/flowbasic
@@ -8,9 +8,8 @@
Note that request and response messages are not automatically replied to,
so we need to implement handlers to do this.
"""
-import os
-from libmproxy import flow, proxy
-from libmproxy.proxy.server import ProxyServer
+from libmproxy import flow
+from libmproxy.proxy import ProxyServer, ProxyConfig
class MyMaster(flow.FlowMaster):
@@ -34,7 +33,7 @@ class MyMaster(flow.FlowMaster):
return f
-config = proxy.ProxyConfig(
+config = ProxyConfig(
port=8080,
# use ~/.mitmproxy/mitmproxy-ca.pem as default CA file.
cadir="~/.mitmproxy/"