I looked up for an answer but were not able to find it.
This is my scenario:
- a django application
- I'm using
python-social-auth
to connect to social networks, and Facebook in particular I'm using the default pipeline:
SOCIAL_AUTH_PIPELINE = [ 'social.pipeline.social_auth.social_details', 'social.pipeline.social_auth.social_uid', 'social.pipeline.social_auth.auth_allowed', 'social.pipeline.social_auth.social_user', 'social.pipeline.user.get_username', 'social.pipeline.user.create_user', 'social.pipeline.social_auth.associate_user', 'social.pipeline.social_auth.load_extra_data', 'social.pipeline.user.user_details', ]
in my template I add a link to authenticate with Facebook:
<a class="btn btn-default social facebook" href="{% url "social:begin" "facebook" %}" role="button">
The simple operation of logging (through Facebook) works smoothly. The problem I'm having is this:
If I manage two facebook accounts foo
and fie
, and currently I'm logged in (in Facebook) as foo
, when I try to login (through Facebook) on my application, I don't get the chance to choose to login as fie
, but I'm logged in only as foo
. I've to disconnect from the Facebook site, and then come back to my application.
Does python-social-auth provide a "native" way to ask (e.g. in a confirmation window) whether the user wants to login in my application as user foo
(as he/she is currently logged in Facebook) or as someone else?
Also a snippet available on the web would be good :)
Thanks a lot