diff options
author | Aldo Cortesi <aldo@nullcube.com> | 2016-07-14 13:51:00 +1200 |
---|---|---|
committer | Aldo Cortesi <aldo@nullcube.com> | 2016-07-14 19:54:15 +1200 |
commit | a3a22fba337fc4ac750b8c18663233920a0d646b (patch) | |
tree | f274ec77e28b9dc0e260cfb26b63efa15f54f209 /mitmproxy/controller.py | |
parent | 126625584251d6a246ba46943cfa71d5a57fbdda (diff) | |
download | mitmproxy-a3a22fba337fc4ac750b8c18663233920a0d646b.tar.gz mitmproxy-a3a22fba337fc4ac750b8c18663233920a0d646b.tar.bz2 mitmproxy-a3a22fba337fc4ac750b8c18663233920a0d646b.zip |
First-order integration of scripts addon
Diffstat (limited to 'mitmproxy/controller.py')
-rw-r--r-- | mitmproxy/controller.py | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/mitmproxy/controller.py b/mitmproxy/controller.py index 2f0c8bf2..464842b6 100644 --- a/mitmproxy/controller.py +++ b/mitmproxy/controller.py @@ -44,7 +44,17 @@ class Log(object): def __call__(self, text, level="info"): self.master.add_event(text, level) - # We may want to add .log(), .warn() etc. here at a later point in time + def debug(self, txt): + self(txt, "debug") + + def info(self, txt): + self(txt, "info") + + def warn(self, txt): + self(txt, "warn") + + def error(self, txt): + self(txt, "error") class Master(object): |