Azure RBAC Least Privilege for Storage Data View and Role Assignment

AZ-104 By islever Editorial Last updated

Short answer

User1: Reader and Data Access; User2: Owner

Question

DRAG DROP
You have an Azure subscription named Sub1 that contains two users named User1 and User2.
You need to assign role-based access control (RBAC) roles to User1 and User2. The users must be able to perform the following tasks in Sub1:
• User1 must view the data in any storage account.
• User2 must assign users the Contributor role for storage accounts.
The solution must use the principle of least privilege.
Which RBAC role should you assign to each user? To answer, drag the appropriate roles to the correct users. Each role may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content.
NOTE: Each correct selection is worth one point.
Exhibit: Azure RBAC Least Privilege for Storage Data View and Role Assignment

Key Takeaways

The main trap is confusing Storage Account Contributor with data viewing capabilities and failing to recognize that only Owner or User Access Administrator can assign roles.

Determine the correct Azure RBAC roles for viewing storage data and assigning user permissions. User1 gets Reader and Data Access, while User2 receives the Owner role to satisfy least privilege constraints.

Common mistake: Selecting Storage Account Contributor for User1 because it sounds like it manages storage, or selecting Contributor for User2 because it seems powerful enough, ignoring that Contributor cannot assign roles.

Expert Analysis

Least Privilege for Data Viewing User1 requires the ability to view data in storage accounts. The Storage Account Contributor role is a common trap because it includes permissions to manage the storage account itself (create, delete, modify), which violates least privilege and exceeds "view" requirements. While the Reader role allows viewing metadata, it does not grant access to the actual data (blobs/files). Therefore, Reader and Data Access is the correct choice, as it specifically grants read-only access to data via keys or SAS tokens without allowing resource modification.

Role Assignment Capabilities User2 must assign roles to others. This is a critical distinction in Azure RBAC. The Contributor role allows full management of resources but explicitly forbids assigning roles. Only the Owner role and the User Access Administrator role can assign RBAC roles. Since User Access Administrator is often not presented in limited drag-and-drop options or is less powerful than needed if broader management were required, Owner is the standard answer when role assignment is the sole requirement alongside general visibility. It satisfies the need to delegate the Contributor role to other users.

Why Other Options Fail Assigning Storage Account Contributor to User1 is incorrect due to excessive permissions. Assigning Contributor to User2 is incorrect because they cannot fulfill the task of assigning roles. The principle of least privilege demands we separate data access (Reader and Data Access) from administrative delegation (Owner).

Official Reference

Exam Strategy

When an exam question asks for 'least privilege' regarding data access, always distinguish between metadata access (Reader) and data content access (Data Access roles). For role assignment tasks, immediately eliminate Contributor and stick to Owner or User Access Administrator. If User Access Administrator is unavailable or if the user also needs resource management, Owner is the fallback.

Frequently Asked Questions

Can Contributor role assign other users?

No, the Contributor role can manage all resources but cannot assign Azure RBAC roles. Only Owner or User Access Administrator can assign roles.

What is the difference between Reader and Reader and Data Access?

Reader only allows viewing metadata and properties. Reader and Data Access additionally allows reading data within storage accounts using keys or SAS tokens.

Discussion 30 contributions

Compiled from public community threads and reader submissions, lightly edited for clarity. Handles and vote tallies are shown as recorded, and comments reflect the views of individual contributors.

From public community threads 30

  1. Muffay 👍 99
    Answer is correct. "Reader and Data Access": "Lets you view everything but will not let you delete or create a storage account or contained resource. It will also allow read/write access to all data contained in a storage account via access to storage account keys." "Owner" is needed to manage permissions, as "User Access Administrator" is not offered as an option.
  2. jeru81 👍 10
    Answer is wrong. there is a 5th option User Access Administrator, which is cut out here. You see the 5 dots? -Reader and Data Access -User Access Administrator ;)
  3. Ashfaque_9x 👍 4
    User 1: "Reader and Data Access" User 2: "Owner"
  4. KennethLZK 👍 3
    The appropriate role should be "User Acess Administrator" but it is not an option. Therefore, the next "least privilege" role would be "Owner". Storage Account Contributor - Permits management of storage accounts. Provides access to the account key, which can be used to access data via Shared Key authorization. https://learn.microsoft.com/en-us/azure/role-based-access-control/built-in-roles
  5. fe0b3b4 👍 3
    Also User Access Administrator: User Access Administrator: can assign roles but can’t do anything with the actual resources, so manages access but not the resources. Contributor: can do everything with the actual resources but can’t assign roles, so manages the resources but not the access to them. Owner: can do everything, most powerful role in Azure.
Show 25 more comments
  1. Whatsamattr81 👍 3
    View Data in ANY storage account (assume storage account only) Reader and Data Access gives a lot more than just storage account permissions - but Storage account contributor gives you access to do a lot ore than just Read / View data. Tricky one. Neither choices are perfect. But SAC role lets you do more than just 'view' data...
  2. Henryjb3 👍 3
    Would the second answer be Storage Account Contributor, since it is the least privilege?
  3. Rams786 👍 3
    This question was on my exam on 22 Sep 2023. scored 900 i answered most Voted
  4. Ahkhan 👍 3
    I got this question today in my exam—11/14 2023.
  5. VWSAM025 👍 3
    Storage account contributor cannot assign roles
  6. skavichal 👍 2
    user 1 Reader and data access user2 should be owner, Storage Account Contributor can't be possible as it can read roles and roles assignment but can't assign any role to user.
  7. MSBITSM 👍 2
    If there was indeed an option for User Access Administrator, that would be correct. But in this case, owner will do the trick.
  8. SIAMIANJI 👍 2
    User1: Storage Account Contributor User2: Owner
  9. Rednevi 👍 2
    Remember: Contributor can NOT assign roles
  10. 18c2076 👍 1
    Its not okay to be wrong in this instance where you're vomiting it all over the internet. Storage Account Contributor does not follow the principle of least privilege. Storage Account Contributor would allow a user that is requested to ONLY have the ability to READ/VIEW the data in the storage account, to do many other things such as Write/List/Delete/Move the data in the storage accounts. They only need to be able to view/read. Therefore, Reader, and Data Access follow this principle. RBAC roles for Storage Accounts: Role: Read and Data Access - Lets you view everything but will not let you delete or create a storage account or contained resource. It will also allow read/write access to all data contained in a storage account via access to storage account keys. Please see reference documentation from MS Learn on Read and Data Access role: https://learn.microsoft.com/en-us/azure/role-based-access-control/built-in-roles/storage#reader-and-data-access
  11. 18c2076 👍 1
    Storage Account Contributor does not follow the principle of least privilege. Storage Account Contributor would allow a user that is requested to ONLY have the ability to READ/VIEW the data in the storage account, to do many other things such as Write/List/Delete/Move the data in the storage accounts. They only need to be able to view/read. Therefore, Reader, and Data Access follow this principle. RBAC roles for Storage Accounts: Role: Read and Data Access - Lets you view everything but will not let you delete or create a storage account or contained resource. It will also allow read/write access to all data contained in a storage account via access to storage account keys. Please see reference documentation from MS Learn on Read and Data Access role: https://learn.microsoft.com/en-us/azure/role-based-access-control/built-in-roles/storage#reader-and-data-access
  12. kriChe27 👍 1
    User1: Assign the Reader and Data Access role. This role allows User1 to view all resources, including data in storage accounts, without granting permissions to modify or delete the data. User2: Assign the Owner role. This role allows User2 to manage all resources, including assigning roles to other users, which covers the requirement to assign the Contributor role for storage accounts. This ensures that User1 can view data in storage accounts and User2 can assign roles to other users, adhering to the principle of least privilege.
  13. lkjsatlwjwwge 👍 1
    It's true that Reader&Data Access allows writing, but you need to grant the role with the least permissions that will allow viewing, and according to https://learn.microsoft.com/en-us/azure/storage/blobs/authorize-data-operations-portal, Storage Acct Contributor gives you even more permissions. So it ought to be R&DA.
  14. vombat186 👍 1
    WRONG. https://learn.microsoft.com/en-us/azure/role-based-access-control/built-in-roles/storage#reader-and-data-access
  15. Indy429 👍 1
    No you should get Contributor access to be able to go through everything, especially the case studies
  16. nnamacha 👍 1
    There is no role called read and data access. So it's contributor and Storage account contributor
  17. Azc_T 👍 1
    Did you use free access? Are these questions from free access enough to clear exam.
  18. PrepaCertif 👍 1
    La réponse est: User1 = Reader and Data Access User2 = Owner
  19. Athul07 👍 1
    User1: Reader User2: Storage Account Contributor
  20. 3c5adce 👍 1
    How do you access the case studies?
  21. Alandt 👍 1
    Exactly, only owner if I'm correct?
  22. Nickouh 👍 1
    I think so as its least privilege
  23. rodrod 👍 1
    he just explained...
  24. Alandt 👍 1
    Good point!
  25. Amir1909 👍 1
    Correct

Reader comments & corrections

No reader corrections yet — spotted an error or have a note? Share it below.

Log in to comment, report an error, or add a note about this question.

Practice All AZ-104 Questions

Access 100 questions with complete answers and detailed explanations.

View Full AZ-104 Practice Test →

← Back to AZ-104 Study Guide