generalizing auth