diff options
author | Maximilian Hils <git@maximilianhils.com> | 2020-01-27 22:47:11 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-01-27 22:47:11 +0100 |
commit | 9253a6c6a551c9dc776dafcccba086d45e669d6f (patch) | |
tree | 8dc5e605e49b8ce68476d151b2060cfeadd17124 | |
parent | 66fe6530631bae9371401f5a86cf4be797107e5c (diff) | |
parent | f5b76d6230d0e2a123b362348552b38ae463a8ca (diff) | |
download | mitmproxy-9253a6c6a551c9dc776dafcccba086d45e669d6f.tar.gz mitmproxy-9253a6c6a551c9dc776dafcccba086d45e669d6f.tar.bz2 mitmproxy-9253a6c6a551c9dc776dafcccba086d45e669d6f.zip |
Merge pull request #3792 from beth92/patch-1
Update WSGI example
-rw-r--r-- | examples/simple/wsgi_flask_app.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/examples/simple/wsgi_flask_app.py b/examples/simple/wsgi_flask_app.py index 4be38000..bbde6913 100644 --- a/examples/simple/wsgi_flask_app.py +++ b/examples/simple/wsgi_flask_app.py @@ -14,12 +14,12 @@ def hello_world() -> str: return 'Hello World!' -def load(l): +addons = [ # Host app at the magic domain "proxapp.local" on port 80. Requests to this # domain and port combination will now be routed to the WSGI app instance. - return wsgiapp.WSGIApp(app, "proxapp.local", 80) - + wsgiapp.WSGIApp(app, "proxapp.local", 80) # SSL works too, but the magic domain needs to be resolvable from the mitmproxy machine due to mitmproxy's design. # mitmproxy will connect to said domain and use serve its certificate (unless --no-upstream-cert is set) # but won't send any data. # mitmproxy.ctx.master.apps.add(app, "example.com", 443) +] |