You need to enable JavaScript to run this app.
导航

0010-00000016

最近更新时间2024.01.05 16:32:17

首次发布时间2024.01.05 16:32:17

问题描述

桶策略配置非法。

问题原因

用户设置桶策略时,策略中的 Condition 配置中,条件运算符取值非法。

问题示例

您配置桶策略配置时,Condition 配置中的条件运算符取值为非法值 xxx

PUT /?policy HTTP/1.1
Host: bucketname.tos-cn-beijing.volces.com
Date: Fri, 30 Jul 2021 13:59:18 GMT
Authorization: authorization xxx

{
    "Version": "2012-10-17",
    "Statement": [
        {
            "Sid": "1",
            "Effect": "Allow",
            "Action": ["tos:*"],
            "Principal": "*",
            "Resource": ["trn:tos:::bucketname/*"],
            "Condition": {"xxx":{"SourceIp": "192.168.0.0/24"}}
        }        
    ]
}

解决方案

参见桶策略模板及参数说明,正确构造桶策略配置,确保条件运算符取值合法。