I want to download a Blob from a private container in an Azure Storage Account from my local machine using Visual Studio (2022).
To achieve that I am using
DefaultAzureCredential credential = new DefaultAzureCredential();
Uri uri = new Uri("https://xxx.blob.core.windows.net/xxx/xxx.json");
BlobClient blobClient = new BlobClient(uri, credential);
Response<BlobDownloadResult> downloadResponse = blobClient.DownloadContent();
When I execute the code I get the following error
Issuer validation failed. Issuer did not match.
I authenticated in VS 2022 as described here: Managed Identity - how to debug locally
What do I need to do to successfully download the Blob?