Query the Block Public Access configurations of a bucket.
Usage notes
By default, an Alibaba Cloud account has permission to run this command. To run it as a RAM user or with Security Token Service (STS) credentials, the caller must have the oss:GetBucketPublicAccessBlock permission. For more information, see Attach a custom policy to a RAM user.
Command syntax
ossutil api get-bucket-public-access-block --bucket <value> [flags]| Parameter | Type | Description |
|---|---|---|
--bucket | string | Name of the bucket |
For supported global flags, see Command-line options.
This command maps to the GetBucketPublicAccessBlock API operation. For a full list of request and response parameters, see the API reference.
Examples
Query the Block Public Access configurations of examplebucket:
ossutil api get-bucket-public-access-block --bucket examplebucketQuery and display the output in JSON format:
ossutil api get-bucket-public-access-block --bucket examplebucket --output-format jsonQuery and display the output in YAML format:
ossutil api get-bucket-public-access-block --bucket examplebucket --output-format yaml