Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pre-existing cookies (django auth) prevent normal django-auth login after install of facebookconnect #3

Open
mfitzp opened this issue Aug 19, 2010 · 4 comments

Comments

@mfitzp
Copy link

mfitzp commented Aug 19, 2010

Random issue and quite possibly not your problem but I've spent 3hrs tearing my hair out over this. Activating facebookconnect resulting in standard authentication not working (deactivating restored it). It would continue to redirect to the LOGIN_REDIRECT url but without actually logging in.

Anyway, the solution is to clear cookies in the browser. After that it works fine.

:)

@ryanmark
Copy link
Owner

ryanmark commented Sep 6, 2010

While building apps with facebook connect, I dedicated Safari to the testing. I used the 'Reset Safari' option liberally and made the testing much more consistant.

@ghost
Copy link

ghost commented Sep 17, 2010

I'm experiencing a similar problem here and I also spotted a strange behavior that I can't explain: once logged in via FBconnect with freshly cleared cookies I can navigate to modify my local profile (on my profile app) but then if I navigate to the public view of the profile I just edited I get disconnected suddenly and can't reconnect using FBconnect, it takes me to the standard login and the only way to come back to a FBconnect login is to clear the cookies again.
I've been checking the code but have no idea of what is going on. I couldn't find how to serve xd_receiver.htm from app.yaml statically so it is served from django with urls.py and a direct to template. Is it the way to go? any idea why I get disconnected on a specific url within my domain? thanks for any help.

@shacker
Copy link

shacker commented Oct 7, 2010

Pretty sure I'm seeing the same bug, but different symptoms.

  1. Authenticate with FB. Associate with a NEW account. Works perfectly.

  2. Log out of site and out of FB.

  3. Authenticate with FB and attempt to associate with an EXISTING account. Whether I enter a known good or known bad user/pass, I'm passed to LOGIN_REDIRECT without actually having been logged in. Since I have is_authenticated conditionals in my homepage template, the contents of those throw 500 errors.

Thanks for any suggestions.

@ryanmark
Copy link
Owner

ryanmark commented Oct 9, 2010

Are you logging in with a FB account that's already been associated with an account on this site? Do you see this problem if you throroughly clear your cache after you log out?

It may be that your old session is not getting closed properly by facebook or django. Take a look at your cookies after you log out. If facebook is leaving a cookie after you logout, django may be picking it up and thinking you're still logged in to the other account.

Take a look at the facebook connect middleware. I used to put lots of logging in there to check the statuses of pyfacebook and django-auth. Often pyfacebook would think the user was logged into facebook when they weren't. The middleware tries to fix those weird situations by deleting cookies and logging the user out of django-auth. Could be that this behavior is causing the problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants