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
deleteObject ignores isRequesterPays #2862
Comments
Are you sure the requester has the necessary permissions to access the object? |
I believe the permissions are okay. Switching from using Here is a test case which uses MockServer to set expectations on the request being sent. Here is the MockServer log from
|
@jfromme apologies for the long silence. Yes, I can reproduce, the |
Describe the bug
The deleteObject methods in AmazonS3Client do not check or use the request's isRequesterPays value.
Expected Behavior
When a delete object request has isRequesterPays set to true and the target bucket has requester pays enabled then the request should succeed assuming the user has the required permsisions.
Current Behavior
Instead the request fails with an AccessDenied error.
Reproduction Steps
Attempt to delete an object from a requester pays enabled bucket.
Possible Solution
deleteObject should call the populateRequesterPaysHeader as other methods in the client do.
Additional Information/Context
No response
AWS Java SDK version used
1.11.931
JDK version used
8u212
Operating System and version
Alpine Linux 3.9
The text was updated successfully, but these errors were encountered: