microsoft / botbuilder-dotnet

Welcome to the Bot Framework SDK for .NET repository, which is the home for the libraries and packages that enable developers to build sophisticated bot applications using .NET.
https://github.com/Microsoft/botframework
MIT License
864 stars 480 forks source link

Port [#4582] UserAssignedIdentity(WorkloadIdentity) auth fails with 'scope https://api.botframework.com is not valid' #6732

Closed ceciliaavila closed 5 months ago

ceciliaavila commented 5 months ago

The changes in https://github.com/microsoft/botbuilder-js/pull/4607 may need to be ported to maintain parity with microsoft/botbuilder-js.

Fixes #4582 ## Description This PR adds the `/.default` suffix to the scope for MSI authentication. ## Specific Changes - Updated `ManagedIdentityAuthenticator` to add the suffix to the scope. ## Testing These images show the fix working with a bot deployed in _AKS_ and another one deployed in an _Azure App Service_. ![image](https://github.com/southworks/botbuilder-js/assets/44245136/08e88fae-f003-4de6-8bcd-51d4f0d6812c)
ceciliaavila commented 5 months ago

This port is not needed since we couldn't reproduce the issue in BotBuilder-DotNet. Even though the scope doesn't include the '/.default' suffix, the bot authenticates with no errors. image