问题
We have heterogeneous systems consisting of Django and .Net web applications. I primarily work on Django.Is it possible to integrate these heterogeneous systems using Single Sign On ? Any ideas in this regard would be truly appreciated.
Thank You
回答1:
We implement OpenID at our company in a way that the only trusted openid provider is ourself. Because of this, the user doesn't have to use anything special to log into a website. They just click a login button and it pops them over to the main login site. If they've already logged in then it instantly sends them back to the site and they are authenticated. If they haven't logged in yet it asks them to authenticate.
While we don't use .Net we do use multiple languages (Python and PHP are most common) and many open source frameworks (Django, Drupal, Wordpress among others) and we've actually contributed our code back to those communities as open source plugins.
A friend of mine who is a .Net developer uses OpenID in his application so I know that the code to do this is already out there and available.
回答2:
The simplest way to do stuff like this is using SSO -- unfortunately, there aren't many good SSO tools out there for Django.
I'm pretty biased as I work here, but my company, Stormpath (https://stormpath.com) does this sorta thing for you. You basically plug our Django library into settings.py (https://github.com/stormpath/stormpath-django), and it handles SSO for ya.
If a user logs in, for instance, they'll be redirected to a static site at login.yoursite.com, which has a registration page, login page, social login, etc. The user will be logged in, then redirected back to your subdomains. Bam.
This works with any sort of language though -- to interact with the user through your .net app, all you have to do is query the Stormpath API to get the user.
来源:https://stackoverflow.com/questions/4713293/integrating-django-and-net-applications-using-single-sign-on-sso