0032-00000007

Updated at:

Problem description

The value of TargetPrefix parameter in the XML body of the PutBucketLogging request includes non-UTF-8 characters.

Causes

The value of the TargetPrefix parameter in the LoggingEnabled child node of the BucketLoggingStatus node includes characters that are not UTF-8 encoded.

Examples

For example, you initiate the following request:

PUT /?logging HTTP/1.1
Date: GMT Date
Content-Length: ContentLength
Content-Type: application/xml
Authorization: SignatureValue 
Host: BucketName.oss-cn-hangzhou.aliyuncs.com
<?xml version="1.0" encoding="UTF-8"?>
<BucketLoggingStatus>
    <LoggingEnabled>
    		<TargetBucket>TargetBucket</TargetBucket>
        <TargetPrefix>...(non-UTF-8 characters)...</TargetPrefix>
    </LoggingEnabled>
</BucketLoggingStatus>

The error is returned for the sample request because the value of the TargetPrefix parameter in the LoggingEnabled node of the XML request body includes non-UTF-8 characters.

Solutions

Make sure that the request body uses a valid XML structure and that a valid value is specified for the TargetPrefix parameter, as shown in the sample request:

PUT /?logging HTTP/1.1
Date: GMT Date
Content-Length: ContentLength
Content-Type: application/xml
Authorization: SignatureValue 
Host: BucketName.oss-cn-hangzhou.aliyuncs.com
<?xml version="1.0" encoding="UTF-8"?>
<BucketLoggingStatus>
    <LoggingEnabled>
        <TargetBucket>TargetBucket</TargetBucket>
        <TargetPrefix>TargetPrefix</TargetPrefix>
    </LoggingEnabled>
</BucketLoggingStatus>

References