diff --git a/libmproxy/web/__init__.py b/libmproxy/web/__init__.py index 99b190aab..8f98060ca 100644 --- a/libmproxy/web/__init__.py +++ b/libmproxy/web/__init__.py @@ -82,20 +82,17 @@ class WebMaster(flow.FlowMaster): self.shutdown() def handle_request(self, f): - print "req" flow.FlowMaster.handle_request(self, f) if f: f.reply() return f def handle_response(self, f): - print "resp" flow.FlowMaster.handle_response(self, f) if f: f.reply() return f def handle_error(self, f): - print "err" flow.FlowMaster.handle_error(self, f) return f diff --git a/libmproxy/web/app.py b/libmproxy/web/app.py index 7c26c29d0..31b299a3e 100644 --- a/libmproxy/web/app.py +++ b/libmproxy/web/app.py @@ -3,9 +3,15 @@ import os.path import tornado.web +class IndexHandler(tornado.web.RequestHandler): + def get(self): + self.render("index.html") + + class Application(tornado.web.Application): def __init__(self, debug): handlers = [ + (r"/", IndexHandler), ] settings = dict( template_path=os.path.join(os.path.dirname(__file__), "templates"), diff --git a/libmproxy/web/templates/index.html b/libmproxy/web/templates/index.html new file mode 100644 index 000000000..434f15f9a --- /dev/null +++ b/libmproxy/web/templates/index.html @@ -0,0 +1,16 @@ + + +
+ +