Introduction
You can use Identity and Access Management (IAM) for fine-grained permissions management of your CPH resources. If your Huawei Cloud account does not need individual IAM users, you can skip this section.
New IAM users do not have any permissions assigned by default. You need to first add them to one or more groups and attach policies or roles to these groups. The users then inherit permissions from the groups and can perform specified operations on cloud services based on the permissions they have been assigned.
You can grant users permissions using roles and policies. Roles are provided by IAM to define service-based permissions that match users' job responsibilities. Policies define API-based permissions for operations on specific resources under certain conditions, allowing for more fine-grained, secure access control of cloud resources.
If you want to allow or deny the access to an API, use policy-based authorization.
An account has all the permissions required to call all APIs, but IAM users must be assigned the required permissions. The permissions required for calling an API are determined by the actions supported by the API. Only users who have been granted permissions allowing the actions can call the API successfully. For example, if an IAM user wants to query ECSs using an API, the user must have been granted permissions that allow the cph:servers:list action.
Supported Actions
CPH provides system-defined policies that can be used in IAM. You can also create custom policies to supplement system-defined policies for more refined access control. Operations supported by policies are specific to APIs. The following are common concepts related to policies:
- Permissions: statements in a policy that allow or deny certain operations
- APIs: REST APIs that can be called by a user who has been granted specific permissions
- Actions: specific operations that are allowed or denied
- Dependencies: actions which a specific action depends on. When allowing an action for a user, you also need to allow any existing action dependencies for that user.
- IAM projects/Enterprise projects: the authorization scope of a custom policy. A custom policy can be applied to IAM projects or enterprise projects or both. Policies that contain actions for both IAM and enterprise projects can be used and applied for both IAM and Enterprise Management. CPH does not support Enterprise Project. For details about the differences between IAM and enterprise management, see Differences Between IAM and Enterprise Management.
√: supported; x: not supported
Table 1 describes the actions supported by CPH custom policies.
Table 1 Actions supported by CPH custom policies Permission
API
Action
IAM Project
Enterprise Project
Creating a cloud phone server
POST /v2/{project_id}/cloud-phone/servers
cph:servers:create
√
√
Migrating workloads from a cloud phone server to another server
POST /v2/{project_id}/cloud-phone/servers/{server_id}/change
cph:servers:change
√
√
Querying cloud phone servers
GET /v1/{project_id}/cloud-phone/servers
cph:servers:list
√
√
Querying details of a cloud phone server
GET /v1/{project_id}/cloud-phone/servers/{server_id}
cph:servers:get
√
√
Querying cloud phone server flavors
GET /v1/{project_id}/cloud-phone/server-models
cph:system:listServerTypes
√
×
Renaming a cloud phone server
PUT /v1/{project_id}/cloud-phone/servers/{server_id}
cph:servers:updateName
√
√
Changing the flavor of a cloud phone server
POST /v1/{project_id}/cloud-phone/servers/change-server-model
cph:servers:changeType
√
√
Batch restarting cloud phone servers
POST /v1/{project_id}/cloud-phone/servers/batch-restart
cph:servers:restart
√
√
Pushing a shared storage file
POST /v1/{project_id}/cloud-phone/phones/share-files
cph:servers:pushShareFiles
√
√
Querying shared storage files
GET /v1/{project_id}/cloud-phone/servers/share-files
cph:servers:getShareFiles
√
√
Deleting shared storage files
POST /v1/{project_id}/cloud-phone/phones/share-files
cph:servers:deleteShareFiles
√
√
Pushing a shared application
POST /v1/{project_id}/cloud-phone/phones/share-apps
cph:servers:pushShareApps
√
√
Deleting a shared application
DELETE /v1/{project_id}/cloud-phone/phones/share-apps
cph:servers:deleteShareApps
√
√
Changing a key pair
PUT /v1/{project_id}/cloud-phone/servers/open-access
cph:servers:updateKeypair
√
√
Querying encoding servers
GET /v1/{project_id}/cloud-phone/encode-servers
cph:servers:listEncodeServers
√
√
Batch restarting the encoding servers
POST /v1/{project_id}/cloud-phone/encode-servers/batch-restart
cph:servers:restartEncodeServers
√
√
Querying the bandwidth used by a cloud phone
GET /v1/{project_id}/cloud-phone/bandwidths
cph:bandwidths:list
√
×
Modifying a shared bandwidth
PUT /v1/{project_id}/cloud-phone/bandwidths/{band_width_id}
cph:bandwidths:put
√
×
Querying cloud phones
GET /v1/{project_id}/cloud-phone/phones
cph:phones:list
√
√
Querying details of a cloud phone
GET /v1/{project_id}/cloud-phone/phones/{phone_id}
cph:phones:get
√
√
Querying cloud phone flavors
GET /v1/{project_id}/cloud-phone/phone-models
cph:system:listPhoneSpecifications
√
×
Resetting cloud phones
POST /v1/{project_id}/cloud-phone/phones/batch-reset
cph:phones:reset
√
√
Restarting cloud phones
POST /v1/{project_id}/cloud-phone/phones/batch-restart
cph:phones:restart
√
√
Stopping cloud phones
POST /v1/{project_id}/cloud-phone/phones/batch-stop
cph:phones:stop
√
√
Renaming a cloud phone
PUT /v1/{project_id}/cloud-phone/phones/{phone_id}
cph:phones:updateName
√
√
Updating cloud phone attributes
POST /v1/{project_id}/cloud-phone/phones/batch-update-property
cph:phones:updateProperty
√
√
Exporting data on cloud phones
POST /v1/{project_id}/cloud-phone/phones/batch-storage
cph:phones:storage
√
√
Restoring data of cloud phones
POST /v1/{project_id}/cloud-phone/phones/batch-restore
cph:phones:restore
√
√
Diverting cloud phone traffic
POST /v1/{project_id}/cloud-phone/phones-traffic
cph:phones:createTrafficRoute
√
√
Expanding the disk capacity of cloud phones
POST /v1/{project_id}/cloud-phone/phones/expand-volume
cph:phones:expandVolume
√
√
Obtaining information about the cloud phones to be accessed
POST /v1/{project_id}/cloud-phone/phones/batch-connection
cph:phones:getConnections
√
√
Asynchronously running the ADB shell commands
POST /v1/{project_id}/cloud-phone/phones/commands
cph:phones:execCommands
√
√
Synchronously running the ADB shell commands
POST /v1/{project_id}/cloud-phone/phones/sync-commands
cph:phones:execSyncCommands
√
√
Querying the execution status of a task
GET /v1/{project_id}/cloud-phone/jobs/{job_id}
cph:jobs:get
√
×
Querying the execution statuses of all tasks
GET /v1/{project_id}/cloud-phone/jobs
cph:jobs:list
√
×
Batch adding tags
POST /v1/{project_id}/{resource_type}/{resource_id}/tags/action
cph:resource:tagResource
√
√
Batch deleting tags
POST /v1/{project_id}/{resource_type}/{resource_id}/tags/action
cph:resource:unTagResource
√
√
Querying cloud phone servers by tag
POST /v1/{project_id}/{resource_type}/resource_instances/action
cph:resource:listResourcesByTag
√
√
Querying tags of a cloud phone server
GET /v1/{project_id}/{resource_type}/{resource_id}/tags
cph:resource:listTagsForResource
√
√
Querying cloud phone server tags in a specified project
GET /v1/{project_id}/{resource_type}/tags
cph:resource:listTags
√
√
Querying cloud phone images
GET /v1/{project_id}/cloud-phone/images
cph:images:list
√
×
Deleting a cloud phone image
DELETE /v1/{project_id}/cloud-phone/images/{image_id}
cph:images:delete
√
×
Sharing a cloud phone image
POST /v1/{project_id}/cloud-phone/images/{image_id}/members
cph:images:addMembers
√
×
Querying users with whom you shared a cloud phone image
GET /v1/{project_id}/cloud-phone/images/{image_id}/members
cph:images:listMembers
√
×
Stopping sharing of a cloud phone image
DELETE /v1/{project_id}/cloud-phone/images/{image_id}/members/{member_id}
cph:images:deleteMembers
√
×
Querying AZs
GET /v1/{project_id}/cloud-phone/availability-zones
cph:system:listServerTypesSoldOutStatus
√
×
Querying subnets
GET /v1/{project_id}/cloud-phone/subnets
cph:system:listSubnets
√
×
Querying VPC peering connections
GET /v1/{project_id}/cloud-phone/peering-routes
cph:system:listPeerings
√
×
Deleting a VPC peering connection
DELETE /v1/{project_id}/cloud-phone/peering-routes
cph:system:deletePeerings
√
×
Adding a VPC peering connection
POST /v1/{project_id}/cloud-phone/peering-routes
cph:system:createPeerings
√
×
Exporting details of cloud phones
GET /v1/{project_id}/cloud-phone/phones/phone-export
cph:phones:exportDetails
√
√
Creating agencies
POST /v1/{project_id}/agencies
cph:system:createAgencies
√
×
Checking an agency
GET /v1/{project_id}/agencies
cph:system:checkAgencies
√
×
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot