All Products
Search
Document Center

AnalyticDB:RAM authorization

Last Updated:Aug 30, 2024
Resource Access Management (RAM) is a service provided by Alibaba Cloud to manage user identities and resource access permissions. You can use RAM to prevent RAM users from sharing the AccessKey pairs of your Alibaba Cloud account. You can also use RAM to grant minimum permissions to RAM users. RAM uses policies to define permissions.
This topic describes the elements, such as Action, Resource, and Condition, which are defined by ADB. You can use the elements to create policies in RAM. The code (RamCode) in RAM that is used to indicate ADB is adb. You can grant permissions on ADB at the RESOURCE.

General structure of a policy

Policies can be stored as JSON files. The following code provides an example on the general structure of a policy:
{
  "Version": "1",
  "Statement": [
    {
      "Effect": "<Effect>",
      "Action": "<Action>",
      "Resource": "<Resource>",
      "Condition": {
        "<Condition_operator>": {
          "<Condition_key>": [
            "<Condition_value>"
          ]
        }
      }
    }
  ]
}
The following list describes the fields in the policy:
  • Effect: specifies the authorization effect. Valid values: Allow, Deny.
  • Action: specifies one or more API operations that are allowed or denied. For more information, see the Action section of this topic.
  • Resource: specifies one or more resources to which the policy applies. You can use an Alibaba Cloud Resource Name (ARN) to specify a resource. For more information, see the Resource section of this topic.
  • Condition: specifies one or more conditions that are required for the policy to take effect. This is an optional field. For more information, see the Condition section of this topic.
    • Condition_operator: specifies the conditional operators. Different types of conditions support different conditional operators. For more information, see Policy elements.
    • Condition_key: specifies the condition keys.
    • Condition_value: specifies the condition values.

Action

ADB defines the values that you can use in the Action element of a policy statement. The following table describes the values.
  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • API operation: the API operation that you can call to perform the operation.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition key: the condition keys that are defined by the Alibaba Cloud service. The Condition key column does not list the common condition keys that are defined by Alibaba Cloud. For more information about the common condition keys, see Generic Condition Keyword.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
ActionsAPI operationAccess levelResource typeCondition keyAssociated operation
adb:ModifyDBClusterModifyDBClusterupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DescribeAutoRenewAttributeDescribeAutoRenewAttributeget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:ModifyDBClusterSSLModifyDBClusterSSLupdate
All Resources
*
adb:EnableSSL
None
adb:ModifyDBClusterAccessWhiteListModifyDBClusterAccessWhiteListupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeTableStatisticsDescribeTableStatisticsget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:ApplyAdviceByIdApplyAdviceByIdupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeDBClusterSpaceSummaryDescribeDBClusterSpaceSummaryget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:KillProcessKillProcessdelete
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:ModifyDBResourceGroupModifyDBResourceGroupupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DescribeDiagnosisRecordsDescribeDiagnosisRecordsget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:CreateDBResourcePoolCreateDBResourcePoolcreate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeDiagnosisTasksDescribeDiagnosisTasksget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:MigrateDBClusterMigrateDBClusterupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:ModifyDBClusterDescriptionModifyDBClusterDescriptionupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DeleteDBClusterDeleteDBClusterdelete
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:ModifyClusterConnectionStringModifyClusterConnectionStringupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeAuditLogConfigDescribeAuditLogConfigget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeDBClusterPerformanceDescribeDBClusterPerformancelist
All Resources
*
NoneNone
adb:DescribeDBClustersDescribeDBClustersget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/*
NoneNone
adb:ReleaseClusterPublicConnectionReleaseClusterPublicConnectiondelete
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DescribeAvailableResourceDescribeAvailableResourceget
All Resources
*
NoneNone
adb:DescribeDBResourcePoolDescribeDBResourcePoolget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:ModifyAutoRenewAttributeModifyAutoRenewAttributeupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeAccountsDescribeAccountsget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DeleteElasticPlanDeleteElasticPlandelete
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:ModifyMaintenanceActionModifyMaintenanceActionupdate
All Resources
*
NoneNone
adb:UnbindDBResourcePoolWithUserUnbindDBResourcePoolWithUserupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:CreateElasticPlanCreateElasticPlancreate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:ModifyBackupPolicyModifyBackupPolicyupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DescribeLoadTasksRecordsDescribeLoadTasksRecordsget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeDBClusterAccessWhiteListDescribeDBClusterAccessWhiteListget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DescribeComputeResourceDescribeComputeResourceget
All Resources
*
NoneNone
adb:ModifyDBResourcePoolModifyDBResourcePoolupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeDiagnosisSQLInfoDescribeDiagnosisSQLInfoget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeElasticDailyPlanDescribeElasticDailyPlanget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:TagResourcesTagResourcescreate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DescribeSqlPatternDescribeSqlPatternget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeTaskInfoDescribeTaskInfoget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeKernelVersionDescribeKernelVersionlist
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeBackupsDescribeBackupsget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:GrantOperatorPermissionGrantOperatorPermissionupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DescribeDBResourceGroupDescribeDBResourceGroupget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DescribeProcessListDescribeProcessListget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeDiagnosisDimensionsDescribeDiagnosisDimensionsget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:ModifySQAConfigModifySQAConfigupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeAuditLogRecordsDescribeAuditLogRecordsget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeDownloadRecordsDescribeDownloadRecordsget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:ModifyAuditLogConfigModifyAuditLogConfigupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeTablePartitionDiagnoseDescribeTablePartitionDiagnoseget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:BatchApplyAdviceByIdListBatchApplyAdviceByIdListupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeElasticPlanDescribeElasticPlanget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeMaintenanceActionDescribeMaintenanceActionget
All Resources
*
NoneNone
adb:DescribeEIURangeDescribeEIURangeget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DescribeAllDataSourceDescribeAllDataSourceget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:BindDBResourceGroupWithUserBindDBResourceGroupWithUserupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DeleteAccountDeleteAccountdelete
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DescribeSchemasDescribeSchemasget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DescribeColumnsDescribeColumnsget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:ModifyDBClusterPayTypeModifyDBClusterPayTypeupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DescribeResubmitConfigDescribeResubmitConfigget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeSQLPatternsDescribeSQLPatternsget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:ModifyLogBackupPolicyModifyLogBackupPolicyupdate
All Resources
*
NoneNone
adb:DescribeTablesDescribeTablesget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeSQLPlanDescribeSQLPlanget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribePatternPerformanceDescribePatternPerformanceget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:UntagResourcesUntagResourcesdelete
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DescribeAvailableAdvicesDescribeAvailableAdvicesget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:AllocateClusterPublicConnectionAllocateClusterPublicConnectionupdate
DBCluster
acs:adb:*:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DeleteDBResourceGroupDeleteDBResourceGroupdelete
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeDBClusterAttributeDescribeDBClusterAttributeget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:UnbindDBResourceGroupWithUserUnbindDBResourceGroupWithUserupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:ModifyDBClusterResourceGroupModifyDBClusterResourceGroupupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeDBClusterHealthStatusDescribeDBClusterHealthStatusget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:CreateAccountCreateAccountcreate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DescribeDBClusterNetInfoDescribeDBClusterNetInfoget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:UpgradeKernelVersionUpgradeKernelVersionupdate
All Resources
*
NoneNone
adb:DetachUserENIDetachUserENIupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeSQAConfigDescribeSQAConfigget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeInclinedTablesDescribeInclinedTablesget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:AttachUserENIAttachUserENIupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeAppliedAdvicesDescribeAppliedAdvicesget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:CreateDBClusterCreateDBClustercreate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/*
adb:DiskEncryption
adb:EnableSSL
None
adb:DescribeDBClusterResourcePoolPerformanceDescribeDBClusterResourcePoolPerformanceget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:EnableAdviceServiceEnableAdviceServiceupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DownloadDiagnosisRecordsDownloadDiagnosisRecordscreate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeDBClusterSSLDescribeDBClusterSSLget
All Resources
*
NoneNone
adb:DescribeAdviceServiceEnabledDescribeAdviceServiceEnabledget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DeleteDBResourcePoolDeleteDBResourcePooldelete
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:ModifyResubmitConfigModifyResubmitConfigupdate
All Resources
*
NoneNone
adb:DisableAdviceServiceDisableAdviceServiceupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeConnectionCountRecordsDescribeConnectionCountRecordsget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:ModifyDBClusterMaintainTimeModifyDBClusterMaintainTimeupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:ModifyAccountDescriptionModifyAccountDescriptionupdate
All Resources
*
NoneNone
adb:ModifyElasticPlanModifyElasticPlanupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:BindDBResourcePoolWithUserBindDBResourcePoolWithUserupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:CreateDBResourceGroupCreateDBResourceGroupcreate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:ResetAccountPasswordResetAccountPasswordupdate
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone
adb:DescribeAllAccountsDescribeAllAccountsget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeTableAccessCountDescribeTableAccessCountget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeDiagnosisMonitorPerformanceDescribeDiagnosisMonitorPerformanceget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:DescribeSQLPlanTaskDescribeSQLPlanTaskget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
NoneNone
adb:ListTagResourcesListTagResourcesget
DBCluster
acs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
NoneNone

Resource

ADB defines the values that you can use in the Resource. You can attach the policy to a RAM user or a RAM role so that the RAM user or the RAM role can perform a specific operation on a specific resource. The ARN is the unique identifier of the resource on Alibaba Cloud. Take note of the following items:
  • {#}indicates a variable. {#} must be replaced with an actual value. For example, {#ramcode} must be replaced with the actual code of an Alibaba Cloud service in RAM.
  • An asterisk (*) is used as a wildcard. Examples:
    • {#resourceType} is set to *, all resources are specified.
    • {#regionId} is set to *, all regions are specified.
    • {#accountId} is set to *, all Alibaba Cloud accounts are specified.
Resource typeARN
DBClusteracs:adb:{#regionId}:{#accountId}:dbcluster/{#dbclusterId}
DBClusteracs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
DBClusteracs:adb:{#regionId}:{#accountId}:dbcluster/*
DBClusterLakeVersionacs:adb:{#Region}:{#AccountId}:dbcluster/{#DBClusterId}
DBClusteracs:adb:{#regionId}:{#accountId}:null/*
DBClusteracs:adb:*:{#accountId}:dbcluster/{#dbclusterId}
DBClusterLakeVersionacs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}

Condition

ADB defines the values that you can use in the Condition element of a policy statement. The following table describes the values. The following table describes the service-specific condition keys. The common condition keys that are defined by Alibaba Cloud also apply to ADB. For more information about the common condition keys, see Generic Condition Keyword.
The data type determines the conditional operators that you can use to compare the value in a request with the value in a policy statement. You must use conditional operators that are supported by the data type. Otherwise, you cannot compare the value in the request with the value in the policy statement. In this case, the authorization is invalid. For more information about the conditional operators that are supported by each data type, see Policy elements.
Condition keyDescriptionData type
adb:DiskEncryptionWhether to enable cloud disk encryptionString
adb:EnableSSLWhether to enable SSL encryption linkString

What to do next

You can create a custom policy and attach the policy to a RAM user, RAM user group, or RAM role. For more information, see the following topics: