I have created DRF application with Django OAuth Toolkit (DOT) Rest Application with oAuth2 flow. I was planning to use these api's as Single Sign On (SSO). For javascript client it is working fine with "authorization_code" grant type which is returning me access token and refresh token and with those I can authorize and authenticate my javascript application.
But for another Django application I am stuck to do the same. It has its own user database and default authentication backend. I want to authenticate users with SSO user database and create a session on successful login into SSO application (DRF application in my case).
I want to achieve following:
- In Django Application I click on login link.
- It redirect me to SSO login page and ask me to provide user
credentials.
- On successful login I redirect back to Django application and land
on dashboard page after auto login.
If anybody can spare some time and let me know if I am getting wrong anywhere it will be helpful. Thank you in advance.
question from:
https://stackoverflow.com/questions/65923911/django-rest-framework-as-single-sign-on 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…