An enterprise auditor needs to review both Admin Activity and Data Access audit logs for Cloud Storage buckets across all projects within a specific GCP Folder. The auditor must be able to view sensitive Data Access logs containing user access records, but must not be granted permissions to view the actual data stored inside the buckets or modify any Cloud Logging routing configurations. Following Google Cloud security best practices, which IAM role assignment satisfies these requirements with least privilege?
- Grant the Logs Private Logs Viewer role (roles/logging.privateLogViewer) on the target Folder.Answer
- BGrant the Logs Viewer role (roles/logging.viewer) on the target Folder.
- CGrant the Viewer primitive role (roles/viewer) on the target Folder.
- DGrant the Logging Admin role (roles/logging.admin) on the target Folder.
Answer
Granting the Logs Private Logs Viewer predefined role (roles/logging.privateLogViewer) at the Folder level provides read access to both standard audit logs (Admin Activity) and restricted Data Access audit logs across all inherited child projects without providing access to actual underlying storage payload data or log administration capabilities.
The correct answer specifies granting the Logs Private Logs Viewer role (roles/logging.privateLogViewer) at the Folder level. Cloud Logging categorizes Data Access logs under private logs. While roles/logging.viewer only allows viewing Admin Activity, System Event, and Access Transparency logs, roles/logging.privateLogViewer grants access to Data Access logs as well. Furthermore, it does not grant permissions to read actual object contents stored in Cloud Storage or modify logging sinks, adhering strictly to least privilege.
Step-by-Step Solution
Key Concept
Cloud Audit Logs IAM Access Granularity