0
0
Snowflakecloud~20 mins

Role hierarchy in Snowflake - Practice Problems & Coding Challenges

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
Snowflake Role Mastery
Get all challenges correct to earn this badge!
Test your skills under time pressure!
🧠 Conceptual
intermediate
2:00remaining
Understanding Role Inheritance in Snowflake

In Snowflake, roles can inherit privileges from other roles. If Role A is granted to Role B, which of the following statements is true about Role B?

ARole B automatically has all privileges of Role A plus any additional privileges assigned directly to Role B.
BRole B only has the privileges explicitly assigned to it, not those of Role A.
CRole B can only use privileges of Role A if Role A is active at the same time.
DRole A loses its privileges once granted to Role B.
Attempts:
2 left
💡 Hint

Think about how inheritance works in everyday situations, like a child inheriting traits from a parent.

Architecture
intermediate
2:00remaining
Role Hierarchy Design for Least Privilege

You want to design a role hierarchy in Snowflake to follow the principle of least privilege. Which approach best supports this goal?

ACreate multiple roles with specific privileges and grant lower-level roles to higher-level roles as needed.
BCreate a single role with all privileges and assign it to all users.
CAssign privileges directly to users instead of using roles.
DUse only the ACCOUNTADMIN role for all users to simplify management.
Attempts:
2 left
💡 Hint

Think about how giving only what is needed helps keep things secure.

service_behavior
advanced
2:00remaining
Effect of Revoking a Role in a Hierarchy

If Role A is granted to Role B, and Role B is granted to User U, what happens when Role A is revoked from Role B?

AUser U keeps privileges from Role A permanently even after revocation.
BUser U retains privileges from Role A until they log out and log back in.
CUser U loses all privileges that came from Role A immediately.
DRevoking Role A from Role B has no effect on User U's privileges.
Attempts:
2 left
💡 Hint

Consider how removing a key from a chain affects access.

security
advanced
2:00remaining
Preventing Privilege Escalation in Role Hierarchy

Which practice helps prevent privilege escalation through role hierarchy in Snowflake?

AGranting the SECURITYADMIN role to all users so they can manage roles.
BLimiting the assignment of powerful roles like SECURITYADMIN and ACCOUNTADMIN to trusted administrators only.
CAllowing users to create and grant roles freely to manage their own access.
DUsing the PUBLIC role to assign all privileges to new users.
Attempts:
2 left
💡 Hint

Think about who should have the keys to the kingdom.

Best Practice
expert
3:00remaining
Analyzing Role Hierarchy for Access Troubleshooting

You notice a user cannot access a table even though they have a role that should grant access. The role hierarchy is complex. Which step is best to troubleshoot this issue?

AAssume the table is unavailable and restart the Snowflake service.
BImmediately grant the user the ACCOUNTADMIN role to bypass access issues.
CRemove all roles from the user and reassign them randomly to refresh privileges.
DCheck if the user has the role active in their current session and verify the role hierarchy grants the needed privilege.
Attempts:
2 left
💡 Hint

Think about verifying the path of access step-by-step.