Py学习  »  Django

Django allauth google OAuth redirect_uri_不匹配错误

Prasanna • 4 年前 • 410 次点击  

我在我的Django应用程序中使用Google OAuth(通过allauth包)

授权的JavaScript源代码

https://example.com  

授权重定向uri

https://example.com/accounts/google/login/callback/ - login fails
http://example.com/accounts/google/login/callback/ - login succeeds

https协议 在授权重定向uri中重定向URL,它不允许登录,并且失败 错误。如果我有一个 http

我需要做什么才能有一个支持https的重定向URL?

Python社区是高质量的Python/Django开发社区
本文地址:http://www.python88.com/topic/53014
 
410 次点击  
文章 [ 1 ]  |  最新文章 4 年前
Prasanna
Reply   •   1 楼
Prasanna    5 年前

在production settings.py中添加以下内容解决了我的问题: