在 firebase 安全规则语言中,苹果登录的关键字是什么?

What is the keyword for apple sign in, in the firebase security rules language?

在由 Google 创建的自定义 firebase 安全规则语言中 - 用于检查用户是否通过 Sign In with Apple 进行身份验证的关键字是什么?该文档包括“email”、“facebook”、“google”、“github”和“custom”——但不包括phone number auth 或 Sign In with Apple。

phone number 和 apple sign in next codes 使用的关键字是什么?

if auth.provider == “github || auth.provider == ____ || auth.provider == _____ { 

根据文档,auth.provider 可以包含

allows you to easily authenticate to several built-in providers and will generate auth tokens for them. After a user is authenticated with one of the built-in providers, the auth variable will contain the following:

... (e.g "password", "anonymous", "facebook", "github", "google", or "twitter").

这可能意味着苹果不是其中之一。但你可以尝试“苹果”,看看它是否有效

另一个选项:

您可以使用 auth.token.firebase.sign_in_provider,它可以是以下之一:

  • 密码
  • phone
  • google.com
  • facebook.com
  • twitter.com
  • github.com
  • apple.com
  • yahoo.com
  • hotmail.com

所以你可以在规则中使用它