Cloud KMS Inventory Service audit logging

Cloud Audit Logs for Cloud KMS Inventory Service let you track administrative and data-access operations on your resources to help you monitor access and configuration changes. You can query these logs in the Logs Explorer and check which Cloud KMS Inventory Service API methods generate Cloud Audit Logs.

For more information about Cloud Audit Logs, see the following documents:

Service name

To view the Cloud KMS Inventory Service audit logs, do the following:

  1. In the Google Cloud console, go to the Logs Explorer page:

    Go to Logs Explorer

  2. Copy and paste the following query into the Query field of the Logs Explorer, and then click Run query.

        protoPayload.serviceName="kmsinventory.googleapis.com"
      

Methods by permission type

Each IAM permission has a type property, whose value is an enum that can be one of four values: ADMIN_READ, ADMIN_WRITE, DATA_READ, or DATA_WRITE. When you call a method, Cloud KMS Inventory Service generates an audit log whose category is dependent on the type property of the permission required to perform the method. Methods that require an IAM permission with the type property value of DATA_READ, DATA_WRITE, or ADMIN_READ generate Data Access audit logs. Methods that require an IAM permission with the type property value of ADMIN_WRITE generate Admin Activity audit logs.

API methods in the following list that are marked with (LRO) are long-running operations (LROs). These methods usually generate two audit log entries: one when the operation starts and another when it ends. For more information see Audit logs for long-running operations.
Permission type Methods
OTHER google.cloud.kms.inventory.v1.KeyDashboardService.ListCryptoKeys: To enable this log, enable ADMIN_READ under the service cloudkms.googleapis.com.
google.cloud.kms.inventory.v1.KeyTrackingService.GetProtectedResourcesSummary: To enable this log, enable ADMIN_READ under the service cloudkms.googleapis.com.
google.cloud.kms.inventory.v1.KeyTrackingService.SearchProtectedResources: To enable this log, enable ADMIN_READ under the service cloudkms.googleapis.com.

API interface audit logs

For information about how and which permissions are evaluated for each method, see the Identity and Access Management documentation for Cloud KMS Inventory Service.

google.cloud.kms.inventory.v1.KeyDashboardService

The following audit logs are associated with methods belonging to google.cloud.kms.inventory.v1.KeyDashboardService.

ListCryptoKeys

  • Method: google.cloud.kms.inventory.v1.KeyDashboardService.ListCryptoKeys
  • Audit log type: Data access
  • Permissions:
    • cloudkms.cryptoKeys.list - ADMIN_READ
  • Method is a long-running or streaming operation: No.
  • Filter for this method: protoPayload.methodName="google.cloud.kms.inventory.v1.KeyDashboardService.ListCryptoKeys"

google.cloud.kms.inventory.v1.KeyTrackingService

The following audit logs are associated with methods belonging to google.cloud.kms.inventory.v1.KeyTrackingService.

GetProtectedResourcesSummary

  • Method: google.cloud.kms.inventory.v1.KeyTrackingService.GetProtectedResourcesSummary
  • Audit log type: Data access
  • Permissions:
    • cloudkms.cryptoKeys.get - ADMIN_READ
  • Method is a long-running or streaming operation: No.
  • Filter for this method: protoPayload.methodName="google.cloud.kms.inventory.v1.KeyTrackingService.GetProtectedResourcesSummary"

SearchProtectedResources

  • Method: google.cloud.kms.inventory.v1.KeyTrackingService.SearchProtectedResources
  • Audit log type: Data access
  • Permissions:
    • cloudkms.cryptoKeys.get - ADMIN_READ
    • cloudkms.protectedResources.search - ADMIN_READ
  • Method is a long-running or streaming operation: No.
  • Filter for this method: protoPayload.methodName="google.cloud.kms.inventory.v1.KeyTrackingService.SearchProtectedResources"