-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New S3 bucket ownership default breaks the S3 streamwrapper mkdir method. #2674
Comments
Hi @tbenice, Sorry to hear about the issues. I imagine we can just unset the |
Given that the configuration of the bucket can still be changed, |
Apologies for the delay here. We decided to leave The new S3 access control paradigms are too fine-grained for us to reasonably translate into permissions levels, so it's unlikely there will be any additional work in that regard. |
This issue is now closed. Comments on closed issues are hard for our team to see. |
Describe the bug
April 2023 S3 started defaulting all new buckets to 'Bucket owner enforced' ownership setting (https://aws.amazon.com/about-aws/whats-new/2022/12/amazon-s3-automatically-enable-block-public-access-disable-access-control-lists-buckets-april-2023/) . Because of this, any createbucket call with acl settings returns a 400 error "InvalidBucketAclWithObjectOwnership".
This would be fine except that the streamwrapper class mkdir method uses acls by default, and so any use of mkdir returns the 400 error.
Expected Behavior
Using mkdir method of the streamwrapper class should create a bucket successfully.
Current Behavior
mkdir method always returns a 'InvalidBucketAclWithObjectOwnership' error.
Reproduction Steps
mkdir("s3://my-bucket-name");
Possible Solution
in the mkdir method try creating the bucket using 'DeleteBucketOwnershipControls' to allow acls, or remove any acl setting from the method.
Additional Information/Context
No response
SDK version used
^3.0
Environment details (Version of PHP (
php -v
)? OS name and version, etc.)php 8, macos, Pantheon hosting environment.
The text was updated successfully, but these errors were encountered: