TerribleDev / OwinOAuthProviders

OAuth providers for Owin
MIT License
504 stars 236 forks source link

VisualStudioOnline Provider multiple authorizations #135

Open pneborg opened 9 years ago

pneborg commented 9 years ago

When using the VisualStudioOnline provider, I am seeing that after I login using this provider it presents a user with VisualStudio.com authorization dialog each time even if I have previously granted authorization for this application. The result then is it generates multiple authorizations shown under my Visual Studio Online profile (one for each login attempt). Am I missing a concept here or is this an issue with the provider? Is there a way to configure this provider to use an authorization once and then subsequent logins do not require a user to repeat the grant authorization dialog coming from VisualStudio.com. Thank you.

image

jerriep commented 9 years ago

@pneborg It is possible that there is some setting which can be passed to VSO provider which prevents this.

Unfortunately I do not have any availability to look into this at the moment. If you want to fork the repo, see whether you can fix the issue and then submit a PR I would be grateful.

JustMaier commented 8 years ago

Hey @pneborg, I built the VSO provider back in the day and actually worked with the VS Online team at the time to build it. I brought this bug to their attention and they said it was expected behavior. Sad, I know...

wslyvh commented 7 years ago

It's been a while, but didn't anyone found a resolution to this? Or just left it the way it is?

Thanks

pneborg commented 7 years ago

hi @wslyvh I have a solution that I cover in an upcoming Pluralsight course on building an integration with Visual Studio Team Services that utilizes asp.net identity claims to retain the oauth refresh token and check to use it before reauthorizing. This technique could be added to the VSO provider.

wslyvh commented 7 years ago

@pneborg sounds great! I've got a working solution right now as well, by re-using the refreshtoken. Not sure if it fits in with the VSO Provider though. But I'd be happy to help to get a better working solution here.

It's been logged at the VS Uservoice as well tho; https://visualstudio.uservoice.com/forums/330519-team-services/suggestions/9261621-bypass-oauth-grant-step-for-previously-authorized

Keep us posted 👍

TerribleDev commented 7 years ago

@pneborg @wslyvh feell free to submit a PR