Granting the Bucket Listing and Creating Permissions to an IAM User
Scenario
This case describes how to grant an IAM user the permissions to create and list buckets. An IAM user with this permission can create buckets. The created buckets are still owned by the account of the IAM user. The IAM user can view all buckets under the account.
Recommended Configuration
Permissions to create and list buckets are at OBS service-level, which can be implemented only through IAM. You are advised to use IAM custom policies.
Procedure
- Log in to HUAWEI CLOUD and click Console in the upper right corner.
- On the console, hover your cursor over the username in the upper right corner, and choose Identity and Access Management from the drop-down list.
- In the navigation pane, choose Permissions > Policies/Roles > Create Custom Policy.
- Configure parameters for a custom policy. Figure 1 Configuring a custom policy
Table 1 Parameters for configuring a custom policy Parameter
Description
Policy Name
Name of the custom policy
Policy View
Set this parameter based on your own habits. Example: Visual editor.
Policy Content
- Select Allow.
- Select Object Storage Service (OBS).
- Select obs:bucket:CreateBucket from ReadWrite actions and obs:bucket:ListAllMyBuckets from ListOnly actions.
- Select All for resources.
Scope
The default value is Global services.
- Click OK. The custom policy is created.
- Create a user group and assign permissions.
Add the created custom policy to the user group by following the instructions in the IAM document.
- Add the IAM user to be authorized to the user group created by referring to Adding Users to or Removing Users from a User Group. The authorization is complete.
Due to data caching, it takes about 10 to 15 minutes for a custom policy to take effect after the authorization.
Did this article solve your problem?
Thank you for your score!Your feedback would help us improve the website.