Worker IAM Role Permissions

You can instruct Veeam Backup for AWS to launch worker instances in production accounts in the following cases:

  • When performing image-level backup, entire instance and volume-level restore operations for EC2 instances.

To do that, enable worker deployment in production accounts in backup policy settings, instance restore settings or volume-level restore settings, and specify IAM roles that will be attached to the worker instances to allow Veeam Backup for AWS to communicate with these instances.

  • When performing image-level backup and database restore operations for RDS resources.

To do that, specify IAM roles that will be attached to the worker instances to allow Veeam Backup for AWS to communicate with these instances in backup policy settings and database restore settings.

Backup and Restore Permissions

IAM roles require the following permissions to deploy worker instances in production accounts:

Worker IAM Role PermissionsIAM role permissions specified in backup policy settings

{

   "Version": "2012-10-17",

   "Statement": [

       {

           "Action": [

               "ebs:ListChangedBlocks",

               "ebs:ListSnapshotBlocks",

               "ec2:AttachVolume",

               "ec2:AuthorizeSecurityGroupEgress",

               "ec2:AuthorizeSecurityGroupIngress",

               "ec2:CreateKeyPair",

               "ec2:CreateVolume",

               "ec2:CreateSecurityGroup",

               "ec2:DeleteSecurityGroup",

               "ec2:CopySnapshot",

               "ec2:CreateSnapshot",

               "ec2:CreateSnapshots",

               "ec2:CreateTags",

               "ec2:GetEbsDefaultKmsKeyId",

               "ec2:DeleteKeyPair",

               "ec2:DeleteVolume",

               "ec2:DescribeAccountAttributes",

               "ec2:DescribeKeyPairs",

               "ec2:DescribeSecurityGroups",

               "ec2:DetachVolume",

               "ec2:DetachVolume",

               "ec2:DeleteKeyPair",

               "ec2:DeleteSnapshot",

               "ec2:DeleteTags",

               "ec2:DescribeAddresses",

               "ec2:DescribeAvailabilityZones",

               "ec2:DescribeConversionTasks",

               "ec2:DescribeInternetGateways",

               "ec2:DescribeImages",

               "ec2:DescribeInstanceAttribute",

               "ec2:DescribeInstances",

               "ec2:DescribeInstanceTypes",

               "ec2:DescribeNetworkInterfaces",

               "ec2:DescribeRouteTables",

               "ec2:DescribeRegions",

               "ec2:DescribeSecurityGroups",

               "ec2:DescribeSnapshotAttribute",

               "ec2:DescribeSnapshots",

               "ec2:DescribeSubnets",

               "ec2:DescribeTags",

               "ec2:DescribeVolumeAttribute",

               "ec2:DescribeVolumes",

               "ec2:DescribeVpcs",

               "ec2:DescribeVpcEndpoints",

               "ec2:ModifySnapshotAttribute",

               "ec2:ModifyInstanceAttribute",

               "ec2:RevokeSecurityGroupEgress",

               "ec2:RevokeSecurityGroupIngress",

               "ec2:RunInstances",

               "ec2:StartInstances",

               "ec2:TerminateInstances",

               "events:DeleteRule",

               "events:DescribeRule",

               "events:ListTargetsByRule",

               "events:PutRule",

               "events:PutTargets",

               "events:RemoveTargets",

               "iam:GetRole",

               "iam:GetInstanceProfile",

               "iam:GetContextKeysForPrincipalPolicy",

               "iam:ListAccountAliases",

               "iam:ListInstanceProfiles",

               "iam:ListInstanceProfilesForRole",

               "iam:PassRole",

               "iam:SimulatePrincipalPolicy",

               "kms:CreateGrant",

               "kms:DescribeKey",

               "kms:GetKeyPolicy",

               "kms:ListAliases",

               "kms:ListKeys",

               "kms:ReEncryptFrom",

               "kms:ReEncryptTo",

               "rds:ModifyDBInstance",

               "servicequotas:ListServiceQuotas",

               "sns:CreateTopic",

               "sns:DeleteTopic",

               "sns:ListSubscriptionsByTopic",

               "sns:ListTopics",

               "sns:SetTopicAttributes",

               "sns:Subscribe",

               "sns:Unsubscribe",

               "sqs:CreateQueue",

               "sqs:DeleteMessage",

               "sqs:DeleteQueue",

               "sqs:ListQueues",

               "sqs:ReceiveMessage",

               "sqs:SendMessage",

               "sqs:SetQueueAttributes",

               "ssm:DescribeInstanceInformation",

               "ssm:GetParameter"

               "ssm:GetCommandInvocation",

               "ssm:SendCommand"

           ],

                     "Resource": "*",

                     "Effect": "Allow"

         }

   ]

}

 

 

 

Worker IAM Role PermissionsIAM role permissions specified for restore operations

{

   "Version": "2012-10-17",

   "Statement": [

       {

           "Action": [

               "ec2:AllocateAddress",

               "ec2:AssignPrivateIpAddresses",

               "ec2:AssociateAddress",

               "ec2:AttachNetworkInterface",

               "ec2:AttachVolume",

               "ec2:AuthorizeSecurityGroupEgress",

               "ec2:AuthorizeSecurityGroupIngress",

               "ec2:CopySnapshot",

               "ec2:CreateKeyPair",

               "ec2:CreateSecurityGroup",

               "ec2:CreateNetworkInterface",

               "ec2:CreateTags",

               "ec2:CreateVolume",

               "ec2:DeleteKeyPair",

               "ec2:DeleteNetworkInterface",

               "ec2:DeleteSnapshot",

               "ec2:DeleteSecurityGroup",

               "ec2:DeleteTags",

               "ec2:DeleteVolume",

               "ec2:DeregisterImage",

               "ec2:DescribeAccountAttributes",

               "ec2:DescribeAddresses",

               "ec2:DescribeAvailabilityZones",

               "ec2:DescribeImages",

               "ec2:DescribeInstanceAttribute",

               "ec2:DescribeInternetGateways",

               "ec2:DescribeInstances",

               "ec2:DescribeInstanceStatus",

               "ec2:DescribeKeyPairs",

               "ec2:DescribeNetworkInterfaces",

               "ec2:DescribeRegions",

               "ec2:DescribeRouteTables",

               "ec2:DescribeSecurityGroups",

               "ec2:DescribeSnapshots",

               "ec2:DescribeSubnets",

               "ec2:DescribeTags",

               "ec2:DescribeVolumes",

               "ec2:DescribeVpcEndpoints",

               "ec2:DescribeVpcs",

               "ec2:DescribeVpcEndpoints",

               "ec2:DetachVolume",

               "ec2:DisassociateAddress",

               "ec2:GetEbsDefaultKmsKeyId",

               "ec2:ImportImage",

               "ec2:ModifyInstanceAttribute",

               "ec2:ModifyNetworkInterfaceAttribute",

               "ec2:ModifySnapshotAttribute",

               "ec2:ModifyVolume",

               "ec2:RevokeSecurityGroupEgress",

               "ec2:RevokeSecurityGroupIngress",

               "ec2:RunInstances",

               "ec2:StartInstances",

               "ec2:StopInstances",

               "ec2:TerminateInstances",

               "events:DeleteRule",

               "events:DescribeRule",

               "events:ListTargetsByRule",

               "events:PutRule",

               "events:PutTargets",

               "events:RemoveTargets",

               "iam:AddRoleToInstanceProfile",

               "iam:AttachRolePolicy",

               "iam:CreateInstanceProfile",

               "iam:DeleteInstanceProfile",

               "iam:DeleteRolePolicy",

               "iam:DetachRolePolicy",

               "iam:GetContextKeysForPrincipalPolicy",

               "iam:GetInstanceProfile",

               "iam:GetRole",

               "iam:ListAccountAliases",

               "iam:ListAttachedRolePolicies",

               "iam:ListInstanceProfilesForRole",

               "iam:ListRolePolicies",

               "iam:PassRole",

               "iam:PutRolePolicy",

               "iam:RemoveRoleFromInstanceProfile",

               "iam:SimulatePrincipalPolicy",

               "kms:CreateGrant",

               "kms:DescribeKey",

               "kms:GetKeyPolicy",

               "kms:ListAliases",

               "kms:ListKeys",

               "kms:ReEncryptFrom",

               "kms:ReEncryptTo",

               "kms:GenerateDataKeyWithoutPlaintext",

               "rds:ModifyDBInstance",

               "s3:GetBucketLocation",

               "servicequotas:ListServiceQuotas"

               "sqs:CreateQueue",

               "sqs:DeleteMessage",

               "sqs:DeleteQueue",

               "sqs:ListQueues",

               "sqs:ReceiveMessage",

               "sqs:SendMessage",

               "ssm:GetCommandInvocation",

               "ssm:GetParameter",

               "ssm:SendCommand"

           ],

           "Resource": "*",

           "Effect": "Allow"

       }

   ]

}

 

 

To learn how to create IAM roles and assign them the required permissions, see Appendix A. Creating IAM Roles in AWS.

Communication Requirements and Permissions

IAM roles require the following permissions to communicate with worker instances in production accounts:

  • The backup appliance must be granted permissions to assume the IAM roles.

To allow the backup appliance to assume an IAM role, configure trust relationships for the role and add the following statement to the trust policy.

{

 "Version": "2012-10-17",

 "Statement": [

   {

     "Effect": "Allow",

     "Action": "sts:AssumeRole",

     "Principal": {

       "AWS": "<Role ARN>"

     }

   }

 ]

}

Where <Role ARN> is the ARN either of the Impersonation IAM role attached to the backup appliance or of an AWS account to which the backup appliance belongs.

To learn how to configure trust relationships for a role and how to find the ARN of the Impersonation IAM role, see Before You Begin.

  • The Amazon EC2 service must be granted permissions to assume the IAM roles.

To allow the Amazon EC2 service to assume an IAM role, configure trust relationships for the role and add the following statement to the trust policy.

{

 "Version": "2012-10-17",

 "Statement": [

   {

     "Effect": "Allow",

     "Action": "sts:AssumeRole",

     "Principal": {

       "Service": "ec2.amazonaws.com"

     }

   }

 ]

}

To learn how to configure trust relationships, see Before You Begin.

  • The IAM roles must be granted the following permissions:

{

   "Version": "2012-10-17",

   "Statement": [

       {

           "Action": [

               "ec2messages:AcknowledgeMessage",

               "ec2messages:DeleteMessage",

               "ec2messages:FailMessage",

               "ec2messages:GetEndpoint",

               "ec2messages:GetMessages",

               "ec2messages:SendReply",

               "iam:GetContextKeysForPrincipalPolicy",

               "iam:GetRole",

               "iam:ListInstanceProfilesForRole",

               "iam:SimulatePrincipalPolicy",

               "sqs:DeleteMessage",

               "sqs:ListQueues",

               "sqs:ReceiveMessage",

               "sqs:SendMessage",

               "ssm:DescribeAssociation",

               "ssm:DescribeDocument",

               "ssm:GetDeployablePatchSnapshotForInstance",

               "ssm:GetDocument",

               "ssm:GetManifest",

               "ssm:GetParameter",

               "ssm:GetParameters",

               "ssm:ListAssociations",

               "ssm:ListInstanceAssociations",

               "ssm:PutComplianceItems",

               "ssm:PutConfigurePackageResult",

               "ssm:PutInventory",

               "ssm:UpdateAssociationStatus",

               "ssm:UpdateInstanceAssociationStatus",

               "ssm:UpdateInstanceInformation",

               "ssmmessages:CreateControlChannel",

               "ssmmessages:CreateDataChannel",

               "ssmmessages:OpenControlChannel",

               "ssmmessages:OpenDataChannel"

           ],

                     "Resource": "*",

                     "Effect": "Allow"

         }

   ]

}

To learn how to create IAM roles and assign them the required permissions, see Appendix A. Creating IAM Roles in AWS.