How to Enable Anonymous Access to Blob Container in Azure Storage

Bathini Harshitha 200 Reputation points
2024-10-04T10:52:35.3033333+00:00

How can I enable anonymous access to a blob container in Azure Storage, and what steps should I take if anonymous access is not permitted on my storage account?

PS - Based on common issues that we have seen from customers and other sources, we are posting these questions to help the Azure community.

Azure Blob Storage
Azure Blob Storage
An Azure service that stores unstructured data in the cloud as blobs.
2,919 questions
0 comments No comments
{count} votes

Accepted answer
  1. Sumarigo-MSFT 46,446 Reputation points Microsoft Employee
    2024-11-06T13:32:05.2833333+00:00

    If you need to enable anonymous access to a blob container in Azure Storage, you might encounter an issue where public access is not permitted on your storage account. This can happen due to specific settings or policies applied to your account.

    In such cases where anonymous access is not allowed, a recommended solution is to use a Shared Access Signature (SAS). A SAS provides secure delegated access to resources in your storage account, allowing you to control how clients access your data. Here’s how you can proceed:

    Generate a Shared Access Signature (SAS):

    • A SAS token can be created via the Azure portal, Azure Storage Explorer, or programmatically using Azure SDKs.
      • When creating a SAS, you can specify the permissions(e.g,read,write) start and expiry time, and the IP range from which the resources can be accessed.
      Apply the SAS Token to the Blob URL:
    - Once generated, append the SAS token to the blob URL. This URL can then be shared with clients who need access.
    
    **Test the SAS Token**:
    
       - Ensure that the SAS token works as expected by accessing the blob URL with the token appended.
    
       **Adjust Permissions and Settings as Necessary**:
    
       - If specific issues arise, review the permissions and settings of the SAS token to ensure they align with your access requirements.
    
       Using a SAS token offers a secure way to grant access without enabling public access at the storage account level, which can help maintain security while meeting your access needs.
    
    
    

    For more detailed steps and best practices on using SAS, you can refer to the official documentation: Best practices when using SAS.

    Hope this helps. If you have any follow-up questions, please let me know. I would be happy to help.

    Please do not forget to "Accept the answer" and "up-vote" wherever the information provided helps you, as this can be beneficial to other community members.

    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. Deleted

    This answer has been deleted due to a violation of our Code of Conduct. The answer was manually reported or identified through automated detection before action was taken. Please refer to our Code of Conduct for more information.


    Comments have been turned off. Learn more

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.