if safe and (repo_base != grantor):
            raise Exception('%s does not have permission to search security'
                            'policies on %s.%s.' % (grantor, repo, table))