Help Center> Graph Engine Service> API Reference> Permissions Policies and Supported Actions

Permissions Policies and Supported Actions

This chapter describes fine-grained permissions management for your GES. If your HUAWEI CLOUD account does not need individual IAM users, then you may skip over this chapter.

By default, new IAM users do not have permissions assigned. You need to add the users to one or more groups, and attach permissions policies or roles to these groups. The users then inherit permissions from the groups to which they are added. After authorization, the users can perform specified operations on GES based on the permissions. For more information about policy syntax and example policies, see Permissions Management.

Type: There are roles and policies.
  • Roles: A type of coarse-grained authorization mechanism that defines permissions related to user responsibilities. This mechanism provides only a limited number of service-level roles for authorization. When using roles to grant permissions, you need to also assign other roles on which the permissions depend to take effect. However, roles are not an ideal choice for fine-grained authorization and secure access control.
  • Policies: A type of fine-grained authorization mechanism that defines permissions required to perform operations on specific cloud resources under certain conditions. This mechanism allows for more flexible policy-based authorization, meeting requirements for secure access control. For example, you can grant GES users only the permissions for managing a certain type of cloud servers.
  • If you want to allow or deny the access to an API, fine-grained authorization is a good choice.
  • Because of the cache, it takes about 13 minutes for an OBS role to take effect after being granted to users and user groups. After a policy is granted, it takes about 5 minutes to take effect.

A HUAWEI CLOUD account has all of the permissions required to call all APIs, but IAM users must have the required permissions specifically assigned. 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 queries graphs using an API, the user must have been granted permissions that allow the ges:graph:list action.

Supported Actions

Operations supported by policies are specific to APIs. The following are common concepts related to policies:

  • Permissions: defined by actions in a custom policy.
  • APIs: RESTful APIs that can be called in a custom policy.
  • Actions: added to a custom policy to control permissions for specific operations.
  • Related actions: Actions on which a specific action depends to take effect. When assigning permissions for the action to a user, you also need to assign permissions for the related actions.
  • IAM or enterprise projects: Type of projects for which an action will take effect. Policies that contain actions supporting both IAM and enterprise projects can be assigned to user groups and take effect in both IAM and Enterprise Management. Policies that only contain actions supporting IAM projects can be assigned to user groups and only take effect in IAM. Such policies will not take effect if they are assigned to user groups in Enterprise Management. For details about the differences between IAM and enterprise projects, see Differences Between IAM and Enterprise Management.

The check mark (√) indicates that an action takes effect. The cross mark (x) indicates that an action does not take effect.

GES supports the following actions that can be defined in custom policies:

Table 1 Actions

Permission

API

Action

Related Action

IAM Project

(Project)

Enterprise Project

Querying the Graph List

GET /v1.0/{project_id}/graphs?offset={offset}&limit={limit}

ges:graph:list

Project-level service VPC

vpc:publicIps:get

Querying Graph Details

GET /v1.0/{project_id}/graphs/{graph_id}

ges:graph:getDetail

  

Creating a Graph

POST /v1.0/{project_id}/graphs

ges:graph:create

Project-level service ECS

ecs:cloudServerFlavors:get

ecs:cloudServerNics:update

Project-level service EVS

evs:types:get

Project-level service VPC

vpc:ports:create

vpc:ports:update

vpc:securityGroups:get

vpc:publicIps:list

vpc:ports:get

vpc:subnets:get

vpc:vpcs:list

Stopping a Graph

POST /v1.0/{project_id}/graphs/{graph_id}/action?action_id=stop

ges:graph:operate

  

Starting a Graph

POST /v1.0/{project_id}/graphs/{graph_id}/action?action_id=start

ges:graph:operate

  

Deleting a Graph

DELETE /v1.0/{project_id}/graphs/{graph_id}

ges:graph:delete

Project-level service VPC

vpc:publicIps:get

vpc:ports:delete

vpc:ports:get

Incrementally Importing Data to Graphs

POST /v1.0/{project_id}/graphs/{graph_id}/action?action_id=import-graph

ges:graph:operate

  

Exporting a Graph

POST /v1.0/{project_id}/graphs/{graph_id}/action?action_id=export-graph

ges:graph:operate

  

Clearing a Graph

POST /v1.0/{project_id}/graphs/{graph_id}/action?action_id=clear-graph

ges:graph:operate

  

Upgrading a Graph

POST /v1.0/{project_id}/graphs/{graph_id}/action?action_id=upgrade

ges:graph:operate

  

Binding EIPs

POST /v1.0/{project_id}/graphs/{graph_id}/action?action_id=bindEip

ges:graph:operate

  

Unbinding EIPs

POST /v1.0/{project_id}/graphs/{graph_id}/action?action_id=unbindEip

ges:graph:operate

  

Viewing the List of All Backups

GET /v1.0/{project_id}/graphs/backups?offset={offset}&limit={limit}

ges:backup:list

  

Viewing the Backup List of a Graph

GET /v1.0/{project_id}/graphs/{graph_id}/backups?offset={offset}&limit={limit}

ges:backup:list

  

Adding a Backup

POST /v1.0/{project_id}/graphs/{graph_id}/backups

ges:backup:create

  

Deleting a Backup

DELETE /v1.0/{project_id}/graphs/{graph_id}/backups/{backup_id}

ges:backup:delete

  

Querying the Metadata List

GET /v1.0/{project_id}/graphs/metadatas?offset={offset}&limit={limit}

ges:metadata:list

  

Querying Metadata

GET /v1.0/{project_id}/graphs/metadatas/{metadata_id}

ges:metadata:list

  

Verifying Metadata

POST /v1.0/{project_id}/graphs/action?action_id=check-schema

ges:metadata:operate

  

Adding Metadata

POST /v1.0/{project_id}/graphs/metadatas

ges:metadata:create

  

Deleting Metadata

DELETE /v1.0/{project_id}/graphs/metadatas/{metadata_id}

ges:metadata:delete

  

Querying Task Status

GET /v1.0/{project_id}/graphs/{graph_id}/jobs/{job_id}/status

ges:jobs:getDetail

  

Querying the Task List

GET /v1.0/{project_id}/graphs/jobs?offset={offset}&limit={limit}

ges:jobs:list