I followed the document to create a console app that retrieves the access_token from MSI. I see the TokenCredential created properly, but code set storageCredential.IsAnonymous to true, thus later it generates StorageException: (Server failed to authenticate the request. Make sure the value of Authorization is fomed correctly including the signatgure. Which version of SDK work for this code? I have verified the environment and test run with Azure CLI after I login in with '--identity'. And, it was working with CLI, which means it is not my environment issue.
⚠Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.
@sjyang18 Thank you for the valuable feedback,we are investigating the issue.
Found a bug in my side. Resource parameter should be 'storage.azure.com'. I was using my library that set 'managment.azure.com'. I will close this. Sorry.
Most helpful comment
Found a bug in my side. Resource parameter should be 'storage.azure.com'. I was using my library that set 'managment.azure.com'. I will close this. Sorry.