wp-media / backwpup

BackWPup - WordPress Backup Plugin
https://backwpup.com
GNU General Public License v2.0
88 stars 36 forks source link

S3 Error executing ListBuckets #92

Open mike-healy opened 4 years ago

mike-healy commented 4 years ago

I use BackWPup on a number of sites with their own IAM user with credentials giving access to a particular bucket path. This has worked for a long time, but seems broken in 3.6.10

This is happening on all my sites.

On the S3 job tab I get this error: Error executing "ListBuckets" on "https://s3.ap-southeast-2.amazonaws.com/"; AWS HTTP error: Client error: 'GET https://s3.ap-southeast-2.amazonaws.com/' resulted in a '403 Forbidden' response: <?xml version="1.0" encoding="UTF-8"?> <Error><Code>AccessDenied</Code><Message>Access Denied</Message><RequestId>ACD02C (truncated...) AccessDenied (client): Access Denied - <?xml version="1.0" encoding="UTF-8"?> <Error><Code>AccessDenied</Code><Message>Access Denied</Message></Error>

The IAM user policy looks like this:

{
    "Version": "2012-10-17",
    "Statement": [
        {
            "Sid": "Stmt1441240868000",
            "Effect": "Allow",
            "Action": "s3:*",
            "Resource": [
                "arn:aws:s3:::[MY_BUCKET]",
                "arn:aws:s3:::[MY_BUCKET]/my/backup/path*"
            ]
        }
    ]
}

I don't want to use overly broad permissions. Thanks

BackWPUp 3.6.10 WordPress 5.2.2 PHP 7.2