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

Configure ReplyUri for AuthorizationCodeCredential #21597

Merged

Conversation

christothes
Copy link
Member

@christothes christothes commented Jun 4, 2021

fixes #21529

@christothes christothes requested a review from schaabs as a code owner June 4, 2021 18:50
@ghost ghost added the Azure.Identity label Jun 4, 2021
@christothes christothes self-assigned this Jun 4, 2021
@christothes christothes added the Client This issue points to a problem in the data-plane of the library. label Jun 4, 2021
@christothes christothes added this to the [2021] June milestone Jun 4, 2021
@christothes christothes merged commit 90db316 into Azure:master Jun 5, 2021
@christothes christothes deleted the chriss/AuthorizationCodeReplyUri branch June 5, 2021 01:28
@sergeyzwezdin
Copy link

@christothes has this change already published to nuget?

@christothes
Copy link
Member Author

Yes, it is 1.5.0-beta.1
https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/identity/Azure.Identity/CHANGELOG.md#fixes-and-improvements

@dmitry-pavlov
Copy link

BTW @christothes, did you see this comment on your commit?

@christothes
Copy link
Member Author

BTW @christothes, did you see this comment on your commit?

Thanks for pointing this out - I missed this. It appears that this is indeed a bug. I'll look into this further.

@dmitry-pavlov
Copy link

@christothes btw what is considered to be the auth code?

Something like this:

M.R3_BL2.c6eeb0f9-e201-13bc-c3fb-3dc650343e93

or longer text we are getting when requesting auth code like this:

M.R3_BL2.c6eeb0f9-e201-13bc-c3fb-3dc650343e93&client_info=eyJ2ZXIiOiIxLjA...wNGI2NmRhZCJ9&state=eyJpZCI6I..fX0%3d

@dmitry-pavlov
Copy link

dmitry-pavlov commented Sep 23, 2021

Thanks for pointing this out - I missed this. It appears that this is indeed a bug. I'll look into this further.

@christothes do you have in mind any estimates on when this could be published as some other beta package?

I see you have created PR 24182 to fix that. I hope it will be included to 1.5.0-beta.5. Just curious when it is going to happen.

@christothes
Copy link
Member Author

It will be released next month

@sergeyzwezdin
Copy link

@christothes I've tried to provide RedirectUri to IConfidentialClientApplication while debugging the app, but it still doesn't work, it fails with the following issue:

AuthorizationCodeCredential authentication failed: AADSTS70000: The provided 'code_verifier' input value does not match the original 'code_challenge.'

Seems PR #24182 doesn't fix the issue. Did you try with real code, not just with unit test?

@christothes
Copy link
Member Author

IConfidentialClientApplication is an MSAL type. Are you saying that outside the context of Azure.Identity, RedirecyUri doesn't work in MSAL? Do you have a code snippet of what you are doing?

@sergeyzwezdin
Copy link

What I actually did is added breakpoint in the code and set RedirectUri by hands during debug, then run the app next. Previously I had the error that redirect_uri is incorrect, now it's about code_verifier and code_challenge.

@christothes
Copy link
Member Author

Would you mind providing a simple repro scenario on this issue and continue the conversation there? #24183

@sergeyzwezdin
Copy link

It's a bit hard to reproduce. If I will be able to create separate repo, I'll add link there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Azure.Identity Client This issue points to a problem in the data-plane of the library.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] AuthorizationCodeCredential does not allow Redirect URI to be defined
4 participants