Repository navigation
Conversation
this test exercises success_redirect_action for PostObject requests, which return a 303 See Also redirect with a Location response header that adds some query params like bucket, key, etag the uploader gives an arbitrary url for that redirect, not one that's served by aws s3. but this test case relies on request.post() to follow that direct back to the rgw endpoint so it can inspect the redirected request's url because of the additional query params on that url, that redirected request now gets rejected by rgw. instead of expecting the test to follow that redirect successfully, disable redirect so that we just expect an http response with status 303 and a Location header with the proper redirect url Signed-off-by: Casey Bodley <[email protected]>
| "max-keys", "prefix", "version-id-marker", | ||
| // rgw extensions | ||
| "allow-unordered", | ||
| "read-stats", |
There was a problem hiding this comment.
multisite uses query param 'objs-container' for bucket listing. should we add it here under rgw extensions?
There was a problem hiding this comment.
thanks, updated. in hindsight, that probably should have been under RGW_SYS_PARAM_PREFIX so it goes to get_sys_params() instead of get_params()
There was a problem hiding this comment.
looks like sigv2 auth params don't contain 'x-amz' prefix https://github.com/ceph/ceph/blob/main/src/rgw/rgw_rest_s3.cc#L7017. will have to add those explicitly.
There was a problem hiding this comment.
overall, it feels like a maintenance burden :(
There was a problem hiding this comment.
overall, it feels like a maintenance burden :(
my main concern with this approach is the risk of regression, by rejecting (malformed?) requests that worked before
i'm not as concerned about maintenance burden. it just means that as we add support for new query paremeters, we'll have to update these lists too. and since we're writing test cases for these features, those tests will hit the "X names an S3 API that rgw does not implement" errors which should make the fix obvious
my concern about the original approach from #72114 is that every time aws introduces a new feature, rgw gains a new way to lose data. in my opinion, my approach here is the only way to prevent these data loss bugs for good
|
initial qa looks mostly good except for multisite failures https://pulpito.ceph.com/cbodley-2026-10-08_13:47:06-rgw-wip-80921-distro-default-trial/ |
s3 uses query parameters to represent "subresources" and routes those requests to different rest apis. rgw supports lots of these subresources, but not all of them - and aws continues to add more rgw does this routing in RGWOp factory functions like RGWHandler_REST_Bucket_S3::op_put(), where we check query parameters for the subresources we support, then fall back to the default resource like RGWCreateBucket_ObjStore_S3 the risk of this strategy is that requests for subresources we don't support get incorrectly mapped to the default bucket/object resource. this can result in data loss when a PUT request falls back to PutObject and overwrites an existing object, or when a DELETE request falls back to DeleteBucket and removes a bucket prematurely to mitigate this risk, both for current subresources that we don't support and for subresources added to aws in the future, we can't fall back to the default resource if the request contains any unrecognized query parameters Fixes: https://tracker.ceph.com/issues/80921 Signed-off-by: Casey Bodley <[email protected]>
|
discussed in the weekly rgw meeting, and the general consensus was for this approach over #72114. additional points made:
for the latter two points, i suggested a config option for each fallback (ex rgw_put_bucket_allowed_params, rgw_delete_object_allowed_params, etc) so that admins could inject additional params they consider to be safe |
s3 uses query parameters to represent "subresources" and routes those requests to different rest apis. rgw supports lots of these subresources, but not all of them - and aws continues to add more
rgw does this routing in RGWOp factory functions like RGWHandler_REST_Bucket_S3::op_put(), where we check query parameters for the subresources we support, then fall back to the default resource like RGWCreateBucket_ObjStore_S3
the risk of this strategy is that requests for subresources we don't support get incorrectly mapped to the default bucket/object resource. this can result in data loss when a PUT request falls back to PutObject and overwrites an existing object, or when a DELETE request falls back to DeleteBucket and removes a bucket prematurely
to mitigate this risk, both for current subresources that we don't support and for subresources added to aws in the future, we can't fall back to the default resource if the request conains any unrecognized query parameters
Fixes: https://tracker.ceph.com/issues/80921
Show available Jenkins commands
jenkins test classic perfJenkins Job | Jenkins Job Definitionjenkins test crimson perfJenkins Job | Jenkins Job Definitionjenkins test signedJenkins Job | Jenkins Job Definitionjenkins test make checkJenkins Job | Jenkins Job Definitionjenkins test make check arm64Jenkins Job | Jenkins Job Definitionjenkins test submodulesJenkins Job | Jenkins Job Definitionjenkins test dashboardJenkins Job | Jenkins Job Definitionjenkins test dashboard cephadmJenkins Job | Jenkins Job Definitionjenkins test apiJenkins Job | Jenkins Job Definitionjenkins test docsReadTheDocs | Github Workflow Definitionjenkins test ceph-volume allJenkins Jobs | Jenkins Jobs Definitionjenkins test windowsJenkins Job | Jenkins Job Definitionjenkins test rook e2eJenkins Job | Jenkins Job DefinitionYou must only issue one Jenkins command per-comment. Jenkins does not understand
comments with more than one command.