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

[BUG][Azure.Identity] Fail to authenticate when using InteractiveBrowserCredential #13940

Closed
erich-wang opened this issue Aug 4, 2020 · 1 comment · Fixed by #14393
Closed
Assignees
Labels
Azure.Identity Client This issue points to a problem in the data-plane of the library. needs-team-triage Workflow: This issue needs the team to triage.

Comments

@erich-wang
Copy link
Member

erich-wang commented Aug 4, 2020

Describe the bug
Get the following exception when using InteractiveBrowserCredential:

MsalClientException: Only loopback redirect uri is supported, but urn:ietf:wg:oauth:2.0:oob was found. Configure http://localhost or http://localhost:port both during app registration and when you create the PublicClientApplication object. See https://aka.ms/msal-net-os-browser for details

To Reproduce
Steps to reproduce the behavior (include a code snippet, screenshot, or any additional information that might help us reproduce the issue)

            string powerShellClientId = "1950a258-227b-4e31-a9cf-717495945fc2";
            string tenantId = "72f988bf-86f1-41af-91ab-2d7cd011db47";

            CancellationToken cancellationToken = new CancellationToken();

            var options = new InteractiveBrowserCredentialOptions()
            {
                ClientId = powerShellClientId,
                EnablePersistentCache = true,
                DisableAutomaticAuthentication = false,
            };
            InteractiveBrowserCredential credential = new InteractiveBrowserCredential(options);
            var r1 = credential.Authenticate();

Environment:

  • Name and version of the Library package used: [Azure.Identity 1.2.0-preview.6]
  • Hosting platform or OS and .NET runtime version (dotnet --info output for .NET Core projects): [.Net core 3.1.302]
  • IDE and version : [e.g. Visual Studio 16.6]
@ghost ghost added the needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. label Aug 4, 2020
@jsquire jsquire added Azure.Identity Client This issue points to a problem in the data-plane of the library. needs-team-triage Workflow: This issue needs the team to triage. labels Aug 5, 2020
@ghost ghost removed the needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. label Aug 5, 2020
@JadeCoding
Copy link

I got this same issue when following steps in this doc: https://docs.microsoft.com/en-us/azure/digital-twins/tutorial-code

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Azure.Identity Client This issue points to a problem in the data-plane of the library. needs-team-triage Workflow: This issue needs the team to triage.
Projects
None yet
4 participants