Commit 4b70cb46 authored by Guilhem Saurel's avatar Guilhem Saurel
Browse files

enable LAASPermsMiddleware

parent c2ef172b
Pipeline #8409 passed with stage
in 1 minute and 18 seconds
......@@ -27,6 +27,7 @@ class LAASPermsMiddleware:
allowed = (request.path.startswith('/admin/') or request.path.startswith('/accounts/')
or request.user and request.user.is_authenticated
or request.method in permissions.SAFE_METHODS and ip_laas(request))
print('allowed', allowed)
return self.get_response(request)
if allowed:
return self.get_response(request)
return HttpResponseForbidden()
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment