Project

General

Profile

Actions

Bug #12917

closed

RGW does not support absolute URI

Added by Wenjun Huang over 8 years ago. Updated about 8 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Target version:
-
% Done:

0%

Source:
other
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

When using goamz as the sdk to access rgw, it will fail. It is because that goamz send absoluteURI to RGW, It is similar to this issue. For rgw, there are different failure reasons between civetweb and Apache as the frontend. They are described as below:

For civetweb:
civetweb does not support the resolving of absoluteURI, so it will fail very quickly with a "400 bad request error". I have made a issue here to civetweb.

For Apache:
Apache will transfer the absoluteURI to rgw, but when doing the authorization, rgw will use the absoluteURI as the input for calculating the signature, so it wont match the signature get from client's request(which is calculated depended on general URI). So it will fail while doing authorization.
With apache as the frontend, I have hacked the source code of rgw, which adjust the req_info::request_uri to abs_path. So the following reference to the req_info::request_uri will get the right value, so as the input for calculating the signature of server side. It works well!

As far as I know, many languages's S3 sdk calculate the client side's signature using abs_path(I have tried Python, Java, Perl, Go). So in my opinion, adjusting the req_info::request_uri to fix this issue is a right way, but I am not sure if it will influence any other part.

If you have any point please feel free to let me know.

Thanks


Related issues 1 (0 open1 closed)

Has duplicate rgw - Bug #15231: radosgw returning 400 bad URIDuplicate03/22/2016

Actions
Actions #1

Updated by Wenjun Huang over 8 years ago

I have made a pull request for my fix: https://github.com/ceph/ceph/pull/5774

Actions #2

Updated by Loïc Dachary over 8 years ago

  • Project changed from Ceph to rgw
Actions #4

Updated by Abhishek Lekshmanan about 8 years ago

  • Status changed from New to Resolved
Actions #5

Updated by Abhishek Lekshmanan about 8 years ago

  • Status changed from Resolved to Fix Under Review
  • Assignee set to Matt Benjamin

This might need a backport.. changing to need Review..

Actions #6

Updated by Nathan Cutler about 8 years ago

  • Related to Bug #15231: radosgw returning 400 bad URI added
Actions #7

Updated by Nathan Cutler about 8 years ago

  • Related to deleted (Bug #15231: radosgw returning 400 bad URI)
Actions #8

Updated by Nathan Cutler about 8 years ago

  • Has duplicate Bug #15231: radosgw returning 400 bad URI added
Actions #9

Updated by Yehuda Sadeh about 8 years ago

  • Status changed from Fix Under Review to Resolved
Actions

Also available in: Atom PDF