Angular.js 中基于 OpenID 连接的身份验证与 (drf oidc) Django 休息框架后端

OpenID connect based authentication in Angular.js with (drf oidc) Django rest framework backend

有没有办法把后端和前端的逻辑都写出来?

在我目前的流程中,我们正在使用 Django rest-framework 登录,现在我们需要在我们的项目中集成 OpenID connect SSO,请指导我如何将 OpenID connect SSO 与 Django-rest 框架集成。

有GitHub例子吗? 我正在寻找示例代码。

这里有用户 angualr Js 和 django-rest-framework-jwt

https://github.com/rmemon/Angular-JS-django-rest-framework-jwt

我们可以使用隐式流,我添加了一个如何在客户端应用程序中使用 OIDC 的示例。

前端获取访问令牌:http://django-oidc-provider.readthedocs.io/en/develop/sections/examples.html#pure-js-client-using-implicit-flow

您还必须在后端验证 ID_TOKEN:

https://openid.net/specs/openid-connect-implicit-1_0.html#IDTokenValidation

示例代码:https://github.com/ranvijay-sachan/django-rest-login-and-social_auth

我已经使用 Google open id connect 对任何 SSO 提供商进行了测试,您可以使用 python 社交身份验证添加以下代码:

how can we integrate any SSO provider using python social auth openid connect?