Skip to content

KMS audit logging

Every KMS cryptographic operation writes a dedicated audit entry. Use these events for security monitoring, compliance reporting, and incident investigation.

Resource type

KMS audit entries use resourceType: "kms_key".

Filter audit logs by kms.* actions to isolate key management activity.

Logged operations

Audit actionOperation
kms.encryptEncrypt
kms.decryptDecrypt
kms.signSign
kms.verifyVerify signature
kms.hmacGenerate HMAC
kms.verify_hmacVerify HMAC
kms.rotateManual rotation
kms.rotate.scheduledAutomatic rotation
kms.exportExport key material

Lifecycle operations such as create, disable, enable, and delete follow standard platform audit patterns for resource management.

Fields recorded

For HTTP API calls, audit entries typically include:

FieldDescription
RegionCloud region where the operation ran
ProjectProject context, if applicable
Key slugIdentifier of the affected key
Key typeCryptographic algorithm
OutcomeSuccess or failure
Key versionVersion used for the operation
Payload sizesSize metadata where applicable
Client IPSource IP of the API request
User agentHTTP user agent string

Exact fields available in your audit log export depend on your organisation’s audit log configuration.

Monitoring recommendations

Set up alerts or periodic reviews for:

  • kms.decrypt — Unusual volume or sources outside expected service accounts
  • kms.export — Any export event warrants immediate review
  • kms.rotate and kms.rotate.scheduled — Confirm rotations match your policy
  • Failed crypto operations — Repeated 400 outcomes may indicate misconfiguration or compromise attempts

Integrations such as Secrets Manager emit kms.encrypt and kms.decrypt events when reading and writing secret values. Correlate these with Secrets Manager audit entries for end-to-end traceability.

Related documentation