You can use customer-managed encryption keys (CMEK)
to protect Eventarc.
The keys are created and managed through Cloud Key Management Service (Cloud KMS). The
following table describes different CMEK issues and how to resolve them when
using Cloud KMS with Eventarc.
Issues that occur when creating or updating Eventarc resources
CMEK issue
Error message
Description
Disabled key
$KEY is not enabled, current state is: DISABLED
The provided Cloud KMS key has been disabled for an
Eventarc resource. Events or messages associated with the
resource are no longer protected.
Key region $REGION must match the resource to be protected
The provided KMS key region is different from the region of the
channel.
Solution:
Use a Cloud KMS key from the same region.
Note that for channels in multi-region eu, you should protect
it using a Cloud KMS key in multi-region europe. For
more information, see
Cloud KMS locations
and Eventarc
multi-region locations.
Organization policy constraint
project/PROJECT_ID violated org policy constraint
Eventarc is integrated with the following two
organization policy constraints to help ensure CMEK usage across an
organization. Any existing Eventarc resource isn't subject
to a policy that is set after the resource is created; however, updating
the resource might fail.
constraints/gcp.restrictNonCmekServices causes all
resource creation requests without a specified Cloud KMS key to
fail.
Ensure that the Eventarc service agent has been granted the
cloudkms.cryptoKeyEncrypterDecrypter
role and has been added as a principal to the Cloud KMS key.
For more information, see
Grant the
Eventarc service account access to a key.
To resolve issues that you might encounter when using externally managed keys
through Cloud External Key Manager (Cloud EKM), see
Cloud EKM error reference.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-03-05 UTC."],[],[]]