C# limitation with Azure SDK

2025-04-08T15:24:23.2066667+00:00

I would like to report an issue I’ve encountered with the Azure SDK for .NET (C#) regarding the generation of SAS URLs for Azure Blob Storage. Specifically, I’ve noticed that the SDK does not produce SAS URLs in the same way as the Azure Portal does when using the "blue button" (i.e., the "Generate SAS token and URL" UI feature).

 

When using the SDK methods such as ToSasQueryParameters and GenerateSasUri, the resulting URLs are either improperly encoded or formatted differently than those generated via the Azure Portal. Attempts to adjust the encoding using Uri.EscapeDataString and Uri.UnescapeDataString have not resolved the discrepancies.

This mismatch affects the usability and reliability of programmatically generated SAS URLs, especially when working in environments that expect consistent URL formats for secure access.

I would appreciate any guidance or clarification on this behavior.

C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
11,399 questions
0 comments No comments
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.