def main():
# Register handler pages
handlers = [
(r'/websocket', WebSocketChatHandler),
(r'/static/(.*)', tornado.web.StaticFileHandler, {'path': 'static'}),
(r'/flags/(.*)', tornado.web.StaticFileHandler, {'path': 'static/flags'}),
(r'/', IndexHandler)
]
# Define the static path
#static_path = path.join( path.dirname(__file__), 'static' )
# Define static settings
settings = {
#'static_path': static_path
}
# Create and start app listening on port 8888
try:
app = tornado.web.Application(handlers, **settings)
app.listen(8888)
print('[*] Waiting on browser connections...')
tornado.ioloop.IOLoop.instance().start()
except Exception as appFail:
print(appFail)
AttackMapServer.py 文件源码
python
阅读 17
收藏 0
点赞 0
评论 0
评论列表
文章目录