I have an ASP.NET MVC 5 application which was migrated to ASP.NET Identity and I am in the progress of implementing OAuth authentification. Before the migration I was using Yahoo with OpenID which did work, but is no longer supported.
All common provider (Google, MS, Facebook, ...) are working fine, but I can't get Yahoo to work.
I am using the THIS provider.
When I do the authentication everything looks fine until it comes back to my page. There await AuthenticationManager.GetExternalLoginInfoAsync()
returns null.
I then checked the complete "request stack" and saw the following "request-flow":
- Post back to
http://mydomain.net/Account/ExternalLogin
- Response with header
Location: https://api.login.yahoo.com/oauth/v2/request_auth?oauth_token=hwwvmgr
- Loging in via Yahoo
- Request to
https://api.login.yahoo.com/oauth/v2/request_auth
- Response with header
Location: http://mydomain.net/signin-yahoo?oauth_token=hwwvmgr&oauth_verifier=p2bppu
- Request to that URL
- Response with header
Location: /Account/ExternalLoginCallback?error=access_denied
Does anybody have an idea why this could happen?
I executed this on a "real domain" which is verified at Yahoo.
The Configuration looks like the following:
var options = new YahooAuthenticationOptions();
options.ConsumerKey = settings.ConsumerKey;
options.ConsumerSecret = settings.ConsumerSecret;
app.UseYahooAuthentication(options);
Found the problem: Was a bug in the provider. If you check the History here:
I just updated the provider to version 1.6 (they just came out last week, so I had not updated yet) and it is working now.