Bird
0
0

You wrote this IAM policy snippet but it fails to apply:

medium📝 Debug Q6 of 15
GCP - Cloud IAM Advanced
You wrote this IAM policy snippet but it fails to apply:
{"bindings": [{"role": "roles/editor", "members": ["alice@example.com"]}]}

What is the error?
AThe bindings key should be 'roles'.
BThe role 'roles/editor' does not exist.
CThe JSON syntax is invalid.
DThe member string is missing the 'user:' prefix.
Step-by-Step Solution
Solution:
  1. Step 1: Check member format in IAM policy

    Members must include type prefix like 'user:' before email.
  2. Step 2: Identify missing prefix

    Here, 'alice@example.com' lacks 'user:' prefix, causing failure.
  3. Final Answer:

    The member string is missing the 'user:' prefix. -> Option D
  4. Quick Check:

    Member format requires prefix = The member string is missing the 'user:' prefix. [OK]
Quick Trick: Always prefix members with user:, serviceAccount:, etc. [OK]
Common Mistakes:
  • Omitting user: prefix in member strings
  • Assuming role names are incorrect
  • Misnaming JSON keys

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More GCP Quizzes