An organization needs to grant a newly contracted developer read-only access to inspect Compute Engine virtual machines and view Cloud Storage objects within a specific Google Cloud project named `dev-sandbox-304`. The access must strictly adhere to the principle of least privilege without granting permissions across other projects. Which of the following actions should the cloud administrator take? (Select TWO.)
- Grant the Compute Viewer (`roles/compute.viewer`) role to the developer on the `dev-sandbox-304` project.Cevap
- Grant the Storage Object Viewer (`roles/storage.objectViewer`) role to the developer on the `dev-sandbox-304` project.Cevap
- CGrant the Editor (`roles/editor`) primitive role to the developer on the `dev-sandbox-304` project.
- DGrant the Compute Viewer (`roles/compute.viewer`) role to the developer at the parent Organization level.
Cevap
Granting the Compute Viewer (`roles/compute.viewer`) role and the Storage Object Viewer (`roles/storage.objectViewer`) role directly on the target project `dev-sandbox-304` provides the exact read-only permissions required while adhering to least privilege.
Assigning predefined roles (`roles/compute.viewer` and `roles/storage.objectViewer`) at the specific project level gives the developer precisely the read permissions required for Compute Engine and Cloud Storage without granting excess rights or broad scope across other projects.
Adım Adım Çözüm
Anahtar Kavram
Applying Least Privilege IAM Role Scope and Predefined Roles