Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

S3 permission error object lock configuration while just click checkbox the object inside the bucket

I gave follwoing permission to Group.

{
    "Version": "2012-10-17",
    "Statement": [
        {
            "Sid": "VisualEditor0",
            "Effect": "Allow",
            "Action": [
                "s3:GetObject",
                "s3:ListBucket",
                "s3:DeleteBucket"
            ],
            "Resource": [
                "arn:aws:s3:::commonbuckettest/*",
                "arn:aws:s3:::commonbuckettest"
            ]
        },
        {
            "Sid": "VisualEditor1",
            "Effect": "Allow",
            "Action": "s3:ListAllMyBuckets",
            "Resource": "*"
        }
    ]
}

This is custom generated policy. In that group I have two users. After loging in with one user and go the corrosponding bucket and as sson as just clicked chekbox to one object, it gives follwoing error:

enter image description here

like image 982
MD. Ashfaqur Rahman Tahashin Avatar asked Oct 19 '25 15:10

MD. Ashfaqur Rahman Tahashin


1 Answers

Its not an error. You did not allow your users to access object lock information in your policy, so it can't be shown. If you want your users to view object lock info, you can add it to your policy. For example:

{
    "Version": "2012-10-17",
    "Statement": [
        {
            "Sid": "VisualEditor0",
            "Effect": "Allow",
            "Action": [
                "s3:GetObject",
                "s3:ListBucket",
                "s3:DeleteBucket"
            ],
            "Resource": [
                "arn:aws:s3:::commonbuckettest/*",
                "arn:aws:s3:::commonbuckettest"
            ]
        },
        {
            "Sid": "AllowObjectLockConfiguration",
            "Effect": "Allow",
            "Action": "s3:GetBucketObjectLockConfiguration",
            "Resource": "*"
        },
        {
            "Sid": "VisualEditor1",
            "Effect": "Allow",
            "Action": "s3:ListAllMyBuckets",
            "Resource": "*"
        }
    ]
}
like image 126
Marcin Avatar answered Oct 21 '25 06:10

Marcin



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!