Retrieves the hotlink protection configuration of a bucket.
Usage notes
By default, the owner of an Alibaba Cloud account has permission to query hotlink protection configurations. To query the configuration as a RAM user or using Security Token Service (STS), the caller must have the oss:GetBucketReferer permission. For more information, see Attach a custom policy to a RAM user.
Syntax
ossutil api get-bucket-referer --bucket <value> [flags]Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
--bucket | string | Yes | The name of the bucket whose hotlink protection configuration you want to query. |
For global flags supported by all ossutil commands, see Global command-line options.
get-bucket-referer maps to the GetBucketReferer API operation. For a full description of the returned fields, see the API reference.Examples
Query the hotlink protection configuration of examplebucket:
ossutil api get-bucket-referer --bucket examplebucketDisplay the output in JSON format:
ossutil api get-bucket-referer --bucket examplebucket --output-format jsonDisplay the output in YAML format:
ossutil api get-bucket-referer --bucket examplebucket --output-format yaml