Preventing Modification of Blobs in Azure Storage Account

Prevent Modifying Blobs in Azure Storage Account

Question

You have an Azure Storage account named storage1 that has a container named container1.

You need to prevent the blobs in container1 from being modified.

What should you do?

Answers

Explanations

Click on the arrows to vote for the correct answer

A. B. C. D.

B

https://docs.microsoft.com/en-us/azure/storage/blobs/storage-blob-immutable-storage?tabs=azure-portal

The correct answer is B. From container1, add an access policy.

Explanation: Azure Storage provides various access policies to manage the permissions on containers and blobs. An access policy is a set of permissions that define who can perform operations on a container or blob, and what level of access they have.

To prevent the blobs in container1 from being modified, you can add an access policy that allows read-only access to the container. This will prevent users or applications from modifying the blobs in the container.

Here are the steps to add an access policy to container1:

  1. Navigate to the storage account named storage1 in the Azure portal.
  2. Click on the container named container1.
  3. Click on the "Access policy" tab.
  4. Click on the "Add policy" button.
  5. Enter a name for the access policy and select "Read" as the permission.
  6. Enter the start and expiry time for the access policy, or leave it blank for a permanent policy.
  7. Click on the "OK" button to save the access policy.

Once you have added the access policy, anyone who wants to modify the blobs in container1 will need to have a higher level of permission than read-only. By default, only the owner of the storage account has full access to all containers and blobs. Therefore, it is important to manage access policies carefully to prevent unauthorized modifications.

Option A, changing the access level of container1, is not the correct answer because changing the access level only changes the level of public access to the container. It does not control who can modify the blobs inside the container.

Option C, modifying the Access Control (IAM) settings, is not the correct answer because IAM settings control who has access to the storage account itself, not individual containers or blobs.

Option D, enabling soft delete for blobs, is not the correct answer because soft delete only enables you to recover blobs that have been accidentally deleted. It does not prevent modification of the blobs in the first place.