def ensure_audit_security(perm_arg):
    def _wrapper(f):
        def _decorator(self, *args, **kwargs):
            if not any([name == AUDIT_SECURITY and argument == perm_arg for name, argument, _, _
                    in self.current_user.my_permissions()]):
                return self.forbidden()

            return f(self, *args, **kwargs)

        return wraps(f)(_decorator)

    return _wrapper
Decorator for web handler methods to ensure the current_user has the
dataset/ETHPy150Open dropbox/grouper/grouper/fe/util.py/ensure_audit_security