Files
doc-exports/docs/obs/perms-cfg/obs_40_0031.html
zhangyue 6ae4b62d6f OBS PREMISSION DOC
Reviewed-by: Sabelnikov, Dmitriy <dmitriy.sabelnikov@t-systems.com>
Co-authored-by: zhangyue <zhangyue164@huawei.com>
Co-committed-by: zhangyue <zhangyue164@huawei.com>
2025-04-25 08:19:55 +00:00

6.2 KiB

Granting Anonymous Users the Public Read Permission for a Bucket

Scenario

If a bucket needs to be accessed by anonymous users, you can configure a bucket policy and bucket ACL to grant the access permission to anonymous users. The following uses a bucket policy as an example.

Procedure

  1. In the navigation pane of OBS Console, choose Object Storage.
  2. In the bucket list, click the bucket name you want to go to the Objects page.
  3. In the navigation pane, choose Permissions > Bucket Policies.
  4. On the Bucket Policies page, click Create.
  5. Configure a bucket policy.

    Figure 1 Configuring a bucket policy
    Table 1 Parameters for configuring a bucket policy

    Parameter

    Description

    Policy view

    Select Visual Editor or JSON based on your own habits. Visual Editor is used here.

    Policy Name

    Enter a policy name.

    Effect

    Select Allow.

    Principal

    • Select All accounts.

    Resources

    • Select Entire bucket (including the objects in it).

    Actions

    • Choose Use a template.
    • Select Public Read.

  6. Confirm and click Create.

Verification

  1. After the permission is set, in the Domain Name Details area of the bucket overview page, locate Access Domain Name. Share the URL of the access domain name over the Internet so that all Internet users can access the bucket.
  2. On the Objects tab page of the bucket, click the target object name and find the object link. Share the object link over the Internet so that all Internet users can access the object.