0033-00000005

更新时间:
复制 MD 格式

Problem description

A required node is missing from the XML configuration in the request body.

Causes

You sent a PutBucketReferer request to configure hotlink protection. However, the required RefererList node is missing from the XML configuration in the request body.

Examples

The XML configuration in the request body is missing the required node RefererList.

PUT /?referer HTTP/1.1
Date: Fri, 24 Feb 2017 03:15:40 GMT
Content-Length: 322
Content-Type: application/xml
Host: oss-example.oss-cn-hangzhou.aliyuncs.com
Authorization: OSS qn6q**************:77Dv****************

<?xml version="1.0" encoding="UTF-8"?>
<RefererConfiguration>
	<AllowEmptyReferer>false</AllowEmptyReferer>
  <AllowTruncateQueryString>32</AllowTruncateQueryString>
</RefererConfiguration>

Solutions

Add the RefererList node to the XML structure in the request body. This node is a container for the Referer whitelist.

PUT /?referer HTTP/1.1
Date: Fri, 24 Feb 2017 03:15:40 GMT
Content-Length: 322
Content-Type: application/xml
Host: oss-example.oss-cn-hangzhou.aliyuncs.com
Authorization: OSS qn6q**************:77Dv****************

<?xml version="1.0" encoding="UTF-8"?>
<RefererConfiguration>
  <AllowEmptyReferer>false</AllowEmptyReferer>
  <AllowTruncateQueryString>false</AllowTruncateQueryString>
  <RefererList>
        <Referer>http://www.aliyun.com</Referer>
  </RefererList>
</RefererConfiguration>

References