【发布时间】:2016-10-13 17:55:51
【问题描述】:
我正在尝试使用 django-two-factor-auth 和 Google Authenticator 实现多因素身份验证。但是每次我扫描二维码时,它都会说“输入的令牌无效。”
经过大量研究,我尝试了以下方法:
- 我已经尝试将 Django 版本降级到 1.8
- Google Authenticator 代码时间校正(表示已同步)。
- 将服务器的时区更改为 IST(我的本地时区)。
- 尝试了django-two-factor-auth 中的示例应用程序(在我的本地系统上。即使这样也行不通!)。艰难,他们的在线示例应用程序正在运行 (http://example-two-factor-auth.herokuapp.com/)。
我正在使用 django 1.9 和最新版本的 Google Authenticator (Android)。我不知道这可能是什么原因。
谢谢。
【问题讨论】:
-
我遇到了类似的问题,虽然它可以在我的机器上本地运行,但一旦在登台服务器上就无法运行,很奇怪。对此 +1
标签: django two-factor-authentication google-authenticator