CC: | tim [...] cpanel.net |
Subject: | _simplify_uri performing uri_encode breaks S3 |
The fix added for bug #126025 breaks connecting to Amazon S3 when the URI contains special characters have been encoded. Apparently, every service but S3, needs to have those characters double-encoded.
From Step 2 in "creating a canonical request" in the following document:
https://docs.aws.amazon.com/general/latest/gr/sigv4-create-canonical-request.html
"Normalize URI paths according to RFC 3986. Remove redundant and relative path components. Each path segment must be URI-encoded twice (except for Amazon S3 which only gets URI-encoded once)."
I have a proposed fix for this and will be submitting a pull request shortly.