Skip to content

Required permissions

The cloud permissions untrust scan uses, per platform. They are not written by hand: the generator reads every check's source and records each cloud API call it can make, so this page changes when the scanner does. Grant the read permissions to the identity that runs the scan. Write and run-command permissions are used only by active checks, which write probe objects or run fixed commands on a host; each check's page says which it does.

Source

Generated from untrust 1.3.0 (commit 7ef462d9a0c3).

Missing permissions never pass

A check that is denied an API call reports ERROR, which is not assessed. It is never counted as a pass. Grant what a check needs, or accept that it stays unassessed.

AWS Nitro Enclaves

Every scan first calls sts:GetCallerIdentity to learn the account it runs in.

Permission Access Checks that use it
cloudtrail:DescribeTrails read CLOUDTRAIL-01, DDB-01, SECRETS-01
cloudtrail:GetEventSelectors read CLOUDTRAIL-01, DDB-01, SECRETS-01
cloudtrail:GetTrailStatus read CLOUDTRAIL-01, DDB-01, SECRETS-01
dynamodb:DescribeContinuousBackups read DDB-01
dynamodb:DescribeTable read DDB-01
dynamodb:GetResourcePolicy read DDB-01
ec2:DescribeInstances read IAM-01, IAM-02, IMDS-01, NITRO-BOOT-01, NITRO-EGRESS-01, VPC-01
ec2:DescribeSecurityGroups read NITRO-EGRESS-01, RDS-01
ec2:DescribeTransitGatewayVpcAttachments read VPC-01
ec2:DescribeVpcPeeringConnections read VPC-01
ec2:GetInstanceUefiData read NITRO-BOOT-01
elasticfilesystem:DescribeBackupPolicy read EFS-01
elasticfilesystem:DescribeFileSystemPolicy read EFS-01
elasticfilesystem:DescribeFileSystems read EFS-01
iam:GetInstanceProfile read IAM-01, IAM-02
iam:GetPolicy read IAM-01, IAM-02
iam:GetPolicyVersion read IAM-01, IAM-02
iam:GetRolePolicy read IAM-01, IAM-02
iam:ListAttachedRolePolicies read IAM-01, IAM-02
iam:ListRolePolicies read IAM-01, IAM-02
iam:ListRoles read KMS-01
iam:ListUsers read KMS-01
iam:SimulatePrincipalPolicy read KMS-01
kms:DescribeKey read DDB-01, EFS-01, KMS-01, KMS-02, RDS-01, SECRETS-01, SSM-01
kms:GetKeyPolicy read KMS-01
kms:ListGrants read KMS-01, KMS-02
rds:DescribeDBInstances read RDS-01
rds:DescribeDBSnapshotAttributes read RDS-01
rds:DescribeDBSnapshots read RDS-01
s3:GetBucketLogging read AUDIT-01
s3:GetBucketObjectLockConfiguration read ROLLBACK-01
s3:GetBucketPolicy read BOOTSTRAP-02, S3-02
s3:GetBucketPublicAccessBlock read S3-01
s3:GetBucketVersioning read AUDIT-01
s3:GetEncryptionConfiguration read S3-02
secretsmanager:DescribeSecret read SECRETS-01
secretsmanager:GetResourcePolicy read SECRETS-01
ssm:DescribeParameters read SSM-01
ssm:GetCommandInvocation read CORE-01, DNS-01, ENCLAVE-01, ENCLAVE-02, ENCLAVE-03, ENCLAVE-04, ENCLAVE-05, ENCLAVE-07, ENV-01, EXEC-01, HOST-01, HOST-02, LOG-01, NAT-01, PORT-01, PROXY-01, RESTART-01, SSH-01, SWAP-01, VSOCK-01
s3:DeleteObject write BOOTSTRAP-01
s3:PutObject write BOOTSTRAP-01
ssm:SendCommand run command CORE-01, DNS-01, ENCLAVE-01, ENCLAVE-02, ENCLAVE-03, ENCLAVE-04, ENCLAVE-05, ENCLAVE-07, ENV-01, EXEC-01, HOST-01, HOST-02, LOG-01, NAT-01, PORT-01, PROXY-01, RESTART-01, SSH-01, SWAP-01, VSOCK-01

These checks call no cloud API; they read only the files or values you pass: ENCLAVE-06, HSM-01, KBS-01, NITRO-ATT-02, NITRO-ATT-03, VAULT-01.

Inventory

When the scan writes a report (--output or --json), it also collects the console's inventory unless you pass --no-inventory. Inventory is read-only and never changes a finding; a call that is denied is recorded as an inventory error. It uses:

cloudtrail:LookupEvents, ec2:DescribeInstances, ec2:DescribeRegions, ec2:DescribeSecurityGroups, iam:GenerateServiceLastAccessedDetails, iam:GetAccessKeyLastUsed, iam:GetInstanceProfile, iam:GetRole, iam:GetServiceLastAccessedDetails, iam:ListAccessKeys, iam:ListRoles, iam:ListUsers, iam:SimulatePrincipalPolicy, kms:DescribeKey, kms:GetKeyPolicy, s3:GetBucketPolicy

Example IAM policy

Every permission above, in three statements. Without UntrustScanActive, the host checks report ERROR (not assessed), and the write probe is refused, so it reports only that the scanning identity cannot write; who else can write is what the bucket-policy check reads. To skip the active checks instead, scan with --read-only. Drop UntrustInventory if you pass --no-inventory. The example uses "Resource": "*"; scope the S3 actions to the state bucket and ssm:SendCommand to the parent instance and the AWS-RunShellScript document. ssm:GetCommandInvocation does not support resource-level scoping.

{
  "Version": "2012-10-17",
  "Statement": [
    {
      "Sid": "UntrustScanRead",
      "Effect": "Allow",
      "Action": [
        "cloudtrail:DescribeTrails",
        "cloudtrail:GetEventSelectors",
        "cloudtrail:GetTrailStatus",
        "dynamodb:DescribeContinuousBackups",
        "dynamodb:DescribeTable",
        "dynamodb:GetResourcePolicy",
        "ec2:DescribeInstances",
        "ec2:DescribeSecurityGroups",
        "ec2:DescribeTransitGatewayVpcAttachments",
        "ec2:DescribeVpcPeeringConnections",
        "ec2:GetInstanceUefiData",
        "elasticfilesystem:DescribeBackupPolicy",
        "elasticfilesystem:DescribeFileSystemPolicy",
        "elasticfilesystem:DescribeFileSystems",
        "iam:GetInstanceProfile",
        "iam:GetPolicy",
        "iam:GetPolicyVersion",
        "iam:GetRolePolicy",
        "iam:ListAttachedRolePolicies",
        "iam:ListRolePolicies",
        "iam:ListRoles",
        "iam:ListUsers",
        "iam:SimulatePrincipalPolicy",
        "kms:DescribeKey",
        "kms:GetKeyPolicy",
        "kms:ListGrants",
        "rds:DescribeDBInstances",
        "rds:DescribeDBSnapshotAttributes",
        "rds:DescribeDBSnapshots",
        "s3:GetBucketLogging",
        "s3:GetBucketObjectLockConfiguration",
        "s3:GetBucketPolicy",
        "s3:GetBucketPublicAccessBlock",
        "s3:GetBucketVersioning",
        "s3:GetEncryptionConfiguration",
        "secretsmanager:DescribeSecret",
        "secretsmanager:GetResourcePolicy",
        "ssm:DescribeParameters",
        "ssm:GetCommandInvocation",
        "sts:GetCallerIdentity"
      ],
      "Resource": "*"
    },
    {
      "Sid": "UntrustScanActive",
      "Effect": "Allow",
      "Action": [
        "s3:DeleteObject",
        "s3:PutObject",
        "ssm:SendCommand"
      ],
      "Resource": "*"
    },
    {
      "Sid": "UntrustInventory",
      "Effect": "Allow",
      "Action": [
        "cloudtrail:LookupEvents",
        "ec2:DescribeRegions",
        "iam:GenerateServiceLastAccessedDetails",
        "iam:GetAccessKeyLastUsed",
        "iam:GetRole",
        "iam:GetServiceLastAccessedDetails",
        "iam:ListAccessKeys"
      ],
      "Resource": "*"
    }
  ]
}

GCP Confidential Space (AMD SEV-SNP)

Permission Access Checks that use it
accesscontextmanager.servicePerimeters.list read CSPACE-VPCSC-01
artifactregistry.repositories.getIamPolicy read CSPACE-BINAUTHZ-01, CSPACE-IMG-01, CSPACE-IMG-02
cloudkms.cryptoKeys.getIamPolicy read CSPACE-KMS-01, CSPACE-KMS-02
compute.firewalls.list read CSPACE-EGRESS-01
compute.instances.get read CSPACE-BINAUTHZ-01, CSPACE-DEBUG-01, CSPACE-EGRESS-01, CSPACE-IMG-01, CSPACE-IMG-02, CSPACE-INTEG-01, CSPACE-LAUNCH-01, CSPACE-LAUNCH-02, CSPACE-LAUNCH-03, CSPACE-LAUNCH-04, CSPACE-LAUNCH-05, CSPACE-META-01, CSPACE-SA-01, CSPACE-SAKEY-01, CSPACE-VM-01, CSPACE-VM-02
compute.instances.getEffectiveFirewalls read CSPACE-EGRESS-01
compute.instances.getIamPolicy read CSPACE-META-01
iam.serviceAccountKeys.list read CSPACE-SAKEY-01
iam.serviceAccounts.getIamPolicy read CSPACE-SA-01
iam.workloadIdentityPoolProviders.get read CSPACE-KEYBIND-01, CSPACE-KEYBIND-03
iam.workloadIdentityPoolProviders.list read CSPACE-WIF-02
logging.logEntries.list read CSPACE-INTEG-01
orgpolicy.policy.get read CSPACE-ORG-01
resourcemanager.folders.get read CSPACE-IAM-INHERIT-01
resourcemanager.projects.get read CSPACE-IAM-INHERIT-01
resourcemanager.projects.getIamPolicy read CSPACE-AUDIT-01
secretmanager.secrets.getIamPolicy read CSPACE-SECRET-01
storage.buckets.get read GCS-BOOT-01
storage.buckets.getIamPolicy read GCS-BOOT-01
storage.objects.create write GCS-BOOT-02
storage.objects.delete write GCS-BOOT-02

These checks call no cloud API; they read only the files or values you pass: CSPACE-ATT-01, CSPACE-ATT-02, CSPACE-ATT-03, CSPACE-SIGNER-01, CSPACE-TOKEN-01.

Example custom role

The read permissions as a custom role. Add the write permissions only to an identity that runs active checks.

gcloud iam roles create untrustScanner --project=<project> \
  --title="untrust scanner (read-only)" \
  --permissions=accesscontextmanager.servicePerimeters.list,artifactregistry.repositories.getIamPolicy,cloudkms.cryptoKeys.getIamPolicy,compute.firewalls.list,compute.instances.get,compute.instances.getEffectiveFirewalls,compute.instances.getIamPolicy,iam.serviceAccountKeys.list,iam.serviceAccounts.getIamPolicy,iam.workloadIdentityPoolProviders.get,iam.workloadIdentityPoolProviders.list,logging.logEntries.list,orgpolicy.policy.get,resourcemanager.folders.get,resourcemanager.projects.get,resourcemanager.projects.getIamPolicy,secretmanager.secrets.getIamPolicy,storage.buckets.get,storage.buckets.getIamPolicy

Active checks additionally need storage.objects.create, storage.objects.delete on the bootstrap bucket only.

The scan also collects inventory for the console when it writes a report. Inventory is read-only and never changes a finding: a call that is denied, or an API that is not enabled, is recorded as an inventory error and that section is left out.

Azure confidential VMs

Permission Access Checks that use it
Microsoft.Attestation/attestationProviders/read read AZ-DBG-01, AZ-MAA-01, AZ-SKR-01
Microsoft.Compute/virtualMachines/read read AZ-BOOT-01, AZ-DBG-01, AZ-DISK-01, AZ-SKU-01
Microsoft.KeyVault/vaults/keys/read read AZ-MAA-01, AZ-SKR-01

Example custom role

Reading a key's release policy is a Key Vault data-plane action, so it is listed under DataActions.

{
  "Name": "untrust scanner (read-only)",
  "IsCustom": true,
  "Description": "Read the confidential VM, its disk, the attestation provider and the release key's policy.",
  "Actions": [
    "Microsoft.Attestation/attestationProviders/read",
    "Microsoft.Compute/virtualMachines/read"
  ],
  "NotActions": [],
  "DataActions": [
    "Microsoft.KeyVault/vaults/keys/read"
  ],
  "NotDataActions": [],
  "AssignableScopes": [
    "/subscriptions/<subscription-id>"
  ]
}

The scan also collects inventory for the console when it writes a report. Inventory is read-only and never changes a finding: a call that is denied is recorded as an inventory error and that section is left out.

NVIDIA GPU Confidential Computing

Permission Access Checks that use it
storage.objects.create write GPUCC-MODEL-01
storage.objects.delete write GPUCC-MODEL-01

These checks call no cloud API; they read only the files or values you pass: GPUCC-ATT-01, GPUCC-BIND-01, GPUCC-CERT-01, GPUCC-CUDA-01, GPUCC-CVM-01, GPUCC-DECRYPT-01, GPUCC-DMA-01, GPUCC-FAILOPEN-01, GPUCC-INPUT-01, GPUCC-KEY-01, GPUCC-MEMHYG-01, GPUCC-MIG-01, GPUCC-MODE-01, GPUCC-NONCE-01, GPUCC-NVLINK-01, GPUCC-PERSIST-01, GPUCC-READY-01, GPUCC-REATTEST-01, GPUCC-REVOKE-01, GPUCC-RIM-01, GPUCC-SIGVERIFY-01, GPUCC-TELEMETRY-01, GPUCC-VMM-META-01, GPUCC-VRAM-01.

Checks evaluated from evidence

49 checks are not run by untrust scan against a cloud API. The service evaluates them from evidence you send: signed collector bundles from confidential hosts and image registry scans. They need no cloud permission for untrust. See Enroll a collector.