是否可以使用 Firebase Admin Python SDK 添加 TOTP 多重身份验证?

Is it possible to add TOTP multi-factor authentication using the Firebase Admin Python SDK?

提问人:worstestes 提问时间:10/13/2023 最后编辑:worstestes 更新时间:10/14/2023 访问量:58

问:

我在浏览一些 firebase 文档时遇到了一些麻烦。我在我的 Web 应用上使用 Firebase JS SDK,并在后端使用 Firebase Admin SDK (Python)。我已通过 GCP 启用 Identity Platform。

根据这里的文档: https://firebase.google.com/docs/auth/web/totp-mfa

If you haven't done so already, install the Firebase JavaScript SDK.

TOTP MFA is only supported on the modular Web SDK, versions v9.19.1 and above.

If you haven't done so already, install the Firebase Admin SDK.

TOTP MFA is only supported on Firebase Admin SDK versions 11.6.0 and above.

没有指定此 MFA 功能仅支持 Node.js,但我找不到有关如何在 Python/Flask 环境中执行此操作的任何相关文档。是否可以使用最新的 Firebase Admin Python SDK 使用此功能?

谢谢!

到目前为止,我已经查看了文档,但无法找到任何关于如何使其工作的相关资源/信息。我确实在生产中使用了 Firebase Admin Python SDK。

python firebase 身份验证 firebase-admin 多因素身份验证

评论


答:

1赞 Frank van Puffelen 10/13/2023 #1

我检查了最新版本的 Python Admin SDK,没有看到任何提及 TOTP 支持 - 所以似乎从未添加过这种支持。

我建议在 firebase-admin-python 存储库上提交功能请求,或者更好的是:提交 PR 以添加它。