To ensure security, compliance, and effective troubleshooting, enable Data Access audit logs for your Google Cloud Storage buckets and objects. Cloud Storage provides two main types of audit logs:
- Admin Activity audit logs: These logs capture operations that modify access to resources, such as restoring or managing buckets, folders, or inventory reports. Admin Activity audit logs are enabled by default and cannot be turned off.
- Data Access audit logs: These logs track operations not covered by Admin Activity logs. Data Access audit logs include the following sub-types:
- ADMIN_READ: Logs operations that read access configurations or bucket metadata and list buckets.
- DATA_READ: Logs operations that read or list Cloud Storage resources other than buckets.
- DATA_WRITE: Logs operations that create, modify, or delete objects, manage XML API multipart uploads, or rename folders.
- Data Access audit logs: These logs track operations not covered by Admin Activity logs. Data Access audit logs include the following sub-types:
optimisation
efficiency
excellence
Enabling Data Access audit logs for Google Cloud Storage buckets is crucial for ensuring compliance, strengthening security, promoting accountability, and streamlining troubleshooting efforts. By actively monitoring and analyzing activity within your storage buckets, you can gain valuable insights that enable swift detection and response to potential security threats. In Google Cloud Platform (GCP), Data Access audit logs capture API calls that access resource configurations or metadata, along with user-initiated API calls that create, modify, or read data provided by users.
Audit
To determine if Data Access audit logs are enabled for your Google Cloud Storage buckets and objects, perform the following operations:
Remediation / Resolution
To enable Data Access audit logs for your Google Cloud Storage buckets and objects, perform the following operations:
References
- Google Cloud Platform (GCP) Documentation
- Cloud Audit Logs overview
- Cloud Audit Logs with Cloud Storage
- Enable Data Access audit logs
- GCP Command Line Interface (CLI) Documentation
- gcloud projects list
- gcloud projects get-iam-policy
- gcloud projects set-iam-policy