Made cache_acls use invirt.authz.
[invirt/packages/invirt-web.git] / code / main.py
index 7044167..0b8af46 100755 (executable)
@@ -97,6 +97,9 @@ class InvirtWeb(View):
         return d
 
     def __getattr__(self, name):
+        # At the point __getattr__ is called, tools haven't been run. Make sure the user is logged in.
+        cherrypy.tools.remote_user_login.callable()
+
         if name in ("admin", "overlord"):
             if not cherrypy.request.login in getAfsGroupMembers(config.adminacl, config.authz.afs.cells[0].cell):
                 raise InvalidInput('username', cherrypy.request.login,