1

I've got a site that I'm working on that I just published to beta (which is on the same server as production for now -- it's a personal project). Users have the option of logging in using Google, Facebook or Twitter accounts via OAuth using the MVC 4 SimpleMembership provider.

It all works fantastically when I operate it from the ASP.NET Development server on my local machine. However, on the beta site, OAuthWebSecurity.VerifyAuthentication().IsSuccessful is false (basically meaning the authentication failed). Twitter and Facebook work just fine.

No code has changed, so I'm thinking there must be something specific to the environment. I've inspected the return value of OAuthWebSecurity.VerifyAuthentication() but I don't see any information that would point me towards WHY it failed or what to do to fix it.

Any ideas on what the problem might be or how I can go about getting some kind of an error message from Google? I've inspected the AuthenticationResult object and there's nothing helpful there.

EDIT: My original question had all of the relevant code posted as well but I created a new brand new MVC 4 Internet Application in Visual Studio, uncommented the lined in AuthConfig.cs to enable Google logins and pushed it to production. The same thing happened, so it's not an issue with my code (therefore I removed it from the question).

Scott
  • 13,735
  • 20
  • 94
  • 152
  • Could you try fiddler2 and check what's going on undercovers? – Simon Mourier Jan 08 '13 at 16:50
  • I'm not seeing anything useful in the responses. If someone wants to check it out that has more experience with what to look for in this case, the link above will work indefinitely. – Scott Jan 09 '13 at 01:18

1 Answers1

3

So after losing most of my hair over this one, I finally figured out that my system clock on the server was set a day in the future. Setting it back to the correct time fixed the problem.

Scott
  • 13,735
  • 20
  • 94
  • 152