使用RAM用户权限策略 设置 OSSBrowser 访问指定文件夹(反正我是找了半天,这里有直通车)
policyDocument
策略允许访问 alive-test (bucketName)
下 alive 文件夹下所有
{
"Version": "1",
"Statement": [{
"Effect": "Allow",
"Action": ["oss:ListBuckets", "oss:GetBucketStat", "oss:GetBucketInfo", "oss:GetBucketTagging", "oss:GetBucketAcl"],
"Resource": ["acs:oss:*:*:*"]
}, {
"Effect": "Allow",
"Action": ["oss:GetObject", "oss:GetObjectAcl"],
"Resource": ["acs:oss:*:*:alive-test/alive/*"]
}, {
"Effect": "Allow",
"Action": ["oss:ListObjects"],
"Resource": ["acs:oss:*:*:alive-test"],
"Condition": {
"StringLike": {
"oss:Delimiter": "/",
"oss:Prefix": ["", "alive/*"]
}
}
}]
}