thswlsqls opened a new pull request, #10230:
URL: https://github.com/apache/paimon/pull/10230

   
   ### Purpose
   
   fix #10229
   
   - With `fs.oss.sld.enabled=true` the shared OSS client signs path-style URLs 
(host = endpoint, path = `/bucket/key`), but 
`OSSBlobPresigner.validatePresignedUrl` always expected `bucket.<endpoint>` and 
`/key`, so every request failed with "invalid target" (public, internal and 
PrivateLink endpoints).
   - When the client configuration has SLD enabled, expect the endpoint host 
and `/bucket/key`; bucket, key and HTTPS are still checked. The SLD-off path is 
unchanged.
   - CNAME custom domains are still rejected (out of scope). The Python 
presigner has the same host assumption but no SLD option today.
   
   ### Tests
   
   - Added three `OSSFileIOTest` cases: path-style URLs on 
public/internal/PrivateLink endpoints (plus wrong-bucket rejection), and 
SDK-signed URLs for an encoded key and an endpoint port. All three fail without 
the fix.
   - Stubbed `getClientConfiguration()` in 4 existing mock setups (no assertion 
changes).
   - `mvn -pl paimon-filesystems/paimon-oss-impl clean install` (JDK 11) 
passed: `OSSFileIOTest` 20/20, checkstyle and spotless green.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to