AWS CORS启用

时间:2014-09-28 10:10:31

标签: amazon-web-services amazon-s3

我正在尝试在亚马逊上启用CORS

以下是All Buckets/elsticbeans-west-12345的规则:

<?xml version="1.0" encoding="UTF-8"?>
<CORSConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
    <CORSRule>
        <AllowedOrigin>*</AllowedOrigin>
        <AllowedMethod>GET</AllowedMethod>
        <AllowedMethod>PUT</AllowedMethod>
        <AllowedMethod>POST</AllowedMethod>
        <AllowedMethod>DELETE</AllowedMethod>
        <MaxAgeSeconds>3000</MaxAgeSeconds>
    </CORSRule>
</CORSConfiguration>

据我了解,它应该允许从任何网站完全访问应用程序,但唯一有效的是GET,当我发送不同的请求时,它显示:

NetworkError: 500 Internal Server Error
Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote
resource at pagelink. This can be fixed by moving the resource to the same domain
or enabling CORS.

有人可以解释一下我的规则可能有什么问题。

0 个答案:

没有答案