Verify key access

This page provides instructions on how to verify key access after you create a customer-managed encryption key (CMEK) policy.

Key access verification use cases

At any time, you can rerun key access verification to identify issues with the key:

  • Key disablement: if a key gets disabled, data access to volumes stops.

  • Key destructions: if a key is destroyed, access to data is unrestorable. You can delete volumes to free up capacity. See Delete a volume.

  • Missing permissions: if permissions are removed, the instructions to grant them appear. See Grant the service permission to read a key.

Grant the service permission to read a key

To use a CMEK key, you must grant the service permission to read the specified key first. NetApp Volumes provides the correct Google Cloud CLI commands. To grant the required Cloud KMS key permissions to the service, you need to create a project-wide custom role with the appropriate permissions, and then a key role binding that binds the custom role to the appropriate service account. You need the Role Administrator (roles/iam.RoleAdmin) permissions on the project within your Google Account to create the custom role and the Cloud KMS Admin (roles/cloudkms.admin) permissions to grant NetApp Volumes access to the key.

Console

Use the following instructions to grant the service permission to read a key using the Google Cloud console.

  1. Go to the NetApp Volumes page in the Google Cloud console.

    Go to NetApp Volumes

  2. Select CMEK policies.

  3. Find the CMEK policy you want to edit and click the Show more menu.

  4. Select Verify key access.

  5. If you haven't configured key access yet, the verification fails and the UI shows instructions on how to grant key access. After you run the required Google Cloud CLI commands, click Retry to run key verification again.

    If verification is successful, a dialog appears that indicates successful verification. If verification is unsuccessful, click Retry to rerun the key check.

gcloud

Use the following instructions to grant the service permission to read a key using Google Cloud CLI.

Run the following kms-configs verify command:

 gcloud netapp kms-configs verify CONFIG_NAME \
   --project=PROJECT_ID \
   --location=LOCATION

Replace the following information:

  • CONFIG_NAME: the name of the config.

  • PROJECT_ID: the unique project ID you want to grant access for.

  • LOCATION: the region of the config.

If key verification is successful, the command outputs the following message:

healthy: true

If key verification fails, you have to grant access permissions to the key. Run the following command to identify the Google Cloud CLI commands to grant the service key access. You need the cloudkms.admin role to run the following command.

  gcloud netapp kms-configs describe CONFIG_NAME \
   --project=PROJECT_ID \
   --location=LOCATION \
   --format="value(instructions)"

For more options, see Google Cloud SDK documentation for Cloud Key Management Service.

For more information, see Cloud Key Management Service user documentation.

What's next

Edit or delete a CMEK policy.