Deletes the Block Public Access configurations of a bucket.
Usage notes
By default, Alibaba Cloud accounts have permissions to delete the Block Public Access configurations of a bucket. To perform this operation as a RAM user or by using Security Token Service (STS) credentials, you must have the oss:DeleteBucketPublicAccessBlock permission. For more information, see Common examples of RAM policies.
Request syntax
DELETE /?publicAccessBlock HTTP/1.1
Date: GMT Date
Content-Length: ContentLength
Content-Type: application/xml
Host: BucketName.oss-cn-hangzhou.aliyuncs.com
Authorization: SignatureValue
Request headers
A DeleteBucketPublicAccessBlock request uses only common request headers. For more information, see Common request headers.
Response headers
A DeleteBucketPublicAccessBlock response contains only common response headers. For more information, see Common response headers.
Examples
-
Sample request
DELETE /?publicAccessBlock HTTP/1.1 Date: Mon, 19 Feb 2024 08:40:17 GMT Content-Length: 0 Content-Type: application/xml Host: examplebucket.oss-cn-hangzhou.aliyuncs.com Authorization: OSS4-HMAC-SHA256 Credential=LTAI********************/20250417/cn-hangzhou/oss/aliyun_v4_request,AdditionalHeaders=content-length,Signature=a7c3554c729d71929e0b84489addee6b2e8d5cb48595adfc51868c299c0c218e -
Sample success response
HTTP/1.1 204 OK x-oss-request-id: 534B371674E88A4D8906**** Date: Mon, 19 Feb 2024 08:40:17 GMT Server: AliyunOSS
OSS SDKs
The following OSS SDKs support the DeleteBucketPublicAccessBlock operation:
ossutil
For the ossutil command that corresponds to this operation, see delete-bucket-public-access-block.