def __init__(self): self.routing_map = werkzeug_routing.Map() self.routing_map.add( werkzeug_routing.Rule("/", methods=["HEAD", "GET"], endpoint=webauth.SecurityCheck( self._HandleHomepage))) self.routing_map.add( werkzeug_routing.Rule( "/api/<path:path>", methods=["HEAD", "GET", "POST", "PUT", "PATCH", "DELETE"], endpoint=webauth.SecurityCheck(self._HandleApi))) self.routing_map.add( werkzeug_routing.Rule("/help/<path:path>", methods=["HEAD", "GET"], endpoint=webauth.SecurityCheck( self._HandleHelp)))
def EndpointWrapper(func): return webauth.SecurityCheck(LogAccessWrapper(func))