Now you’re less likely to miss what’s been brewing in our knowledge base with this weekly digest
Please, try again later.
Encrypted snapshots with EBS default key cannot be shared
The default encryption key in the <name> region of your service account is aws/ebs. Snapshots encrypted with aws/ebs cannot be shared
User arn:aws:sts::<AccountId>:role/<RoleName> is not authorized to use resource arn:aws:kms:<RegionName>:<AccountId>:key/<keyID> (Actions: kms:<ActionName>)
To perform backup, snapshot replication, or a restore to an S3 Repository using Customer Master Keys (CMKs), IAM Roles must be allowed to use Encryption Keys involved in the task.
Veeam recommends to use Key Policies to control access to customer master keys.
Veeam Backup for AWS will check for the existence of necessary permissions in the Key Policies of the Encryption Keys for IAM Roles used in the task. If that verification fails, an error message will be displayed in the session log detailing missing permissions and for which IAM Roles in the Key Policy.
The following sections of this article document which permissions are needed and how to add them.
This set of permissions should be given to an IAM Role via a Key Policy to perform cryptographic operations.
"kms:Encrypt", "kms:Decrypt", "kms:ReEncrypt*", "kms:GenerateDataKey*", "kms:DescribeKey" "kms:CreateGrant", "kms:ListGrants", "kms:RevokeGrant"
It’s the set that AWS gives the user of the Key by default. This means that if you add an IAM Role to the Key Policy using Default View, the awarded permissions will be enough.
But if you want to add an IAM Role using Policy View (to add an IAM Role from another account, in any case, you need to use Policy View), then you will need to add them manually.
Note: Veeam Backup for AWS 8 (8.0.0.845) has a known issue where the software may report that the permissions are insufficient despite using the IAM Role example documented below. This issue was fixed in Veeam Backup for AWS 8 Patch 1 (8.1.0.7), please upgrade.
Here is the policy view example:
{
"Id": "key-consolepolicy-3",
"Version": "2012-10-17",
"Statement": [
{
"Sid": "Allow use of the key",
"Effect": "Allow",
"Principal": {
"AWS": "arn:aws:iam:: <accountid>:role/<rolename>"
},
"Action": [
"kms:Encrypt",
"kms:Decrypt",
"kms:ReEncrypt*",
"kms:GenerateDataKey*",
"kms:DescribeKey"
],
"Resource": "*"
},
{
"Sid": "Allow attachment of persistent resources",
"Effect": "Allow",
"Principal": {
"AWS": "arn:aws:iam:: <accountid>:role/<rolename>"
},
"Action": [
"kms:CreateGrant",
"kms:ListGrants",
"kms:RevokeGrant"
],
"Resource": "*",
"Condition": {
"Bool": {
"kms:GrantIsForAWSResource": "true"
}
}
}
]
}
To allow an IAM Role to use the CMK, you need to add the Role as the Key User to the Key Policy. There are two ways to do this:
The set of permissions that AWS gives to the Key User by default will be enough to work with the CMK in Veeam Backup for AWS.
Note: You cannot add an IAM Role from another account using Default Policy view.
The set of required permissions can be found in section The set of permissions required for cryptographic operations
In some cryptographic operations, Veeam Backup for AWS is forced to use a Default Encryption Key in one of your regions to encrypt resources (for example, when you replicate encrypted snapshots without choosing a target key or you restore data from an S3 repository between accounts).
The Default Encryption Key in the region is the key that will encrypt all your resources which must be encrypted unless you explicitly specify the encryption key. (for example, when you create a volume from a shared encrypted snapshot without specifying a target key, it will be encrypted with the region's default key). For more information about Default Encryption Key and creating resources from encrypted sources, see AWS Documentation.
How to change a Default Encryption Key in the region:
This error occurs during a Cross-Account Backup or Snapshot Replication when one or more volumes of the source instance are encrypted using the default AWS KMS encryption key (aws/ebs alias).
One possible solution is to re-encrypt the source volume using a custom key.
You cannot change the CMK associated with an existing snapshot or volume. However, you can associate a different CMK during a snapshot copy or volume creation operation so that the resulting resource is encrypted by the new CMK.
For more information about Snapshot sharing, see AWS Documentation
Another option is to deploy workers in the production account to avoid having to share resources encrypted with the default AWS KMS encryption key.
This error occurs in situations where the snapshot that Veeam is going to encrypt with the Default Encryption Key of the region should be shared, but the Default Encryption Key of the region is the default AWS KMS encryption key (aws/ebs alias).
This happens because AWS does not allow sharing encrypted snapshots using the default AWS KMS encryption key (aws/ebs alias).
To resolve this issue, change the Default Encryption Key in the desired region or deploy workers in the production account to avoid sharing resources encrypted with the default AWS KMS encryption key.
This error occurs when Veeam detects that one of the IAM Roles has no permissions to one of the Encryption Keys.
To resolve it, you must add the missing permissions for the IAM Role to the Key Policy.
Review the section: How to allow an IAM Role to use the CMK.
The error indicates the missing permissions, IAM Role, and Encryption Key identifiers.
Your feedback has been received and will be reviewed.
Please, try again later.
Please try select less.
This form is only for KB Feedback/Suggestions, if you need help with the software open a support case
Your feedback has been received and will be reviewed.
Please, try again later.