We have two apps App1
with domain www.app1.com
and App2
with domain www.app2.com
. Backend of both apps is api based using django-rest-framework
. On frontend side we are using Angular2
. Both apps had their different user base but now we decided to merge the user base and want a single authentication service.
Both apps needs to use eachother's functionality. And we want seemless experience for user. If a user a singed in one app. It should not be login from other app.
I did some research and find out that it can be achieved with SSO
. Here is the link to the relevant stack-overflow question (Implementing SSO with django). I also find many libraries. Most of them are very old so can't use legacy code.
Following are the libraries that I have tried and why these couldn't fit into my problem.
- Server with django-mama-cas and client with django-cas-ng. This worked perfectly but only for session based apps and my client apps are rest-api based.
- Another one is django-rest-framework-sso. This is year old library and also I am not sure how will sure the
jwt
between angular apps.
So can you please share how to implement SSO
with rest-fraemwork
?