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

rgw: fix marker encoding problem. #15998

Merged
merged 1 commit into from Jul 7, 2017

Conversation

Projects
None yet
6 participants
@mdw-at-linuxbox
Contributor

mdw-at-linuxbox commented Jun 29, 2017

For object names that contain / and %, it is possible in
some circumstances (at least with boto) for "listobjects"
operations to attempt to fetch additional objects using
'marker=' and a value containing both / and %. When this
happens, when using AWSv4, radosgw returns a signature
validation error. It's possible to artifically do this
in boto on any bucket (regardless of content) with
sometihng like s=bucket.get_all_keys(marker='level1/8e%25%25FAH3')
this fails because "recoder" assumes the query string
was already encoded if any value is encoded, and fails
to take into account that the string might be partially
encoded, as in this case.

The fix here is to always decode the value, then always encode.

Fixes: http://tracker.ceph.com/issues/20463
Signed-off-by: Marcus Watts mwatts@redhat.com

rgw: fix marker encoding problem.
For object names that contain / and %, it is possible in
some circumstances (at least with boto) for "listobjects"
operations to attempt to fetch additional objects using
'marker=' and a value containing both / and %.  When this
happens, when using AWSv4, radosgw returns a signature
validation error.  It's possible to artifically do this
in boto on any bucket (regardless of content) with
sometihng like s=bucket.get_all_keys(marker='level1/8e%25%25FAH3')
this fails because "recoder" assumes the query string
was already encoded if any value is encoded, and fails
to take into account that the string might be partially
encoded, as in this case.

The fix here is to always decode the value, then always encode.

Fixes: http://tracker.ceph.com/issues/20463
Signed-off-by: Marcus Watts <mwatts@redhat.com>
@mattbenjamin

This comment has been minimized.

Contributor

mattbenjamin commented Jun 30, 2017

@yuriw if you are doing one, can you add this to a test run?

@yuriw

This comment has been minimized.

@yuriw yuriw merged commit c649d57 into ceph:master Jul 7, 2017

4 checks passed

Signed-off-by all commits in this PR are signed
Details
Unmodified Submodules submodules for project are unmodified
Details
default Build finished.
Details
make check make check succeeded
Details
@mattbenjamin

This comment has been minimized.

Contributor

mattbenjamin commented Jul 7, 2017

@yuriw thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment