s3 head object, erroneously modified object name #2982
Labels
bug
This issue is a bug.
needs-review
This issue or pull request needs review from a core team member.
p3
This is a minor priority issue
Acknowledgements
go get -u github.com/aws/aws-sdk-go-v2/...
)Describe the bug
s3 head object:If the object name starts with"/+ bucket name", the SDK will remove the bucket name from the object name in the path of the URL, causing the request to return 404.
code :
[email protected] internal/customizations/update_endpoint.go
func moveBucketNameToHost(u *url.URL, bucket string) { u.Host = bucket + "." + u.Host removeBucketFromPath(u, bucket) }
Regression Issue
Expected Behavior
Object names should not be modified
Current Behavior
If the object name starts with"/+ bucket name", the SDK will remove the bucket name from the object name in the path of the URL
Reproduction Steps
Head An object prefixed with "/+ bucket name"
Possible Solution
No response
Additional Information/Context
No response
AWS Go SDK V2 Module Versions Used
Compiler and Version used
go version go1.21.7 darwin/amd64
Operating System and version
macOS 14.0 (23A344)
The text was updated successfully, but these errors were encountered: