Project

General

Profile

Bug #12728

rgw: value of Swift API's X-Object-Manifest header is not url_decoded during segment look up

Added by Radoslaw Zarzynski over 7 years ago. Updated almost 7 years ago.

Status:
Resolved
Priority:
High
Target version:
-
% Done:

0%

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

Description

A try to get a dynamic large object defined with special characters in its X-Object-Manifest header leads to an error. Exact symptoms depend on used frontend/HTTP server. In case of Apache client will get 500 Internal Server Error while nginx returns 502 Bad Gateway:

$ curl -i "$publicURL/DiscImages2/HP%20Pavilion%20dv7-6c95dx%20Recovery%20Disc%20%281%20of%203%29.ISO" -X GET -H "X-Auth-Token: $token"
HTTP/1.1 502 Bad Gateway
Server: nginx/1.4.6 (Ubuntu)
Date: Wed, 19 Aug 2015 15:20:33 GMT
Content-Type: text/html
Content-Length: 181
Connection: keep-alive

<html>
<head><title>502 Bad Gateway</title></head>
<body bgcolor="white">
<center><h1>502 Bad Gateway</h1></center>
<hr><center>nginx/1.4.6 (Ubuntu)</center>
</body>
</html>

In debug output of radosgw we see:

2015-08-19 17:20:33.163927 7f8ecbfe7700 2 RGWGetObj::handle_user_manifest() prefix=DiscImages2_segments/HP%20Pavilion%20dv7-6c95dx%20Recovery%20Disc%20%281%20of%203%29.ISO/1439995506.197590/16/2/

Segment listing:

$ curl -i "$publicURL/DiscImages2_segments" -X GET -H "X-Auth-Token: $token"
HTTP/1.1 200
Server: nginx/1.4.6 (Ubuntu)
Date: Wed, 19 Aug 2015 15:28:44 GMT
Content-Type: text/plain; charset=utf-8
Transfer-Encoding: chunked
Connection: keep-alive

HP Pavilion dv7-6c95dx Recovery Disc (1 of 3).ISO/1439995506.197590/16/2/00000000
HP Pavilion dv7-6c95dx Recovery Disc (1 of 3).ISO/1439995506.197590/16/2/00000001
HP Pavilion dv7-6c95dx Recovery Disc (1 of 3).ISO/1439995506.197590/16/2/00000002
HP Pavilion dv7-6c95dx Recovery Disc (1 of 3).ISO/1439995506.197590/16/2/00000003
HP Pavilion dv7-6c95dx Recovery Disc (1 of 3).ISO/1439995506.197590/16/2/00000004
HP Pavilion dv7-6c95dx Recovery Disc (1 of 3).ISO/1439995506.197590/16/2/00000005
HP Pavilion dv7-6c95dx Recovery Disc (1 of 3).ISO/1439995506.197590/16/2/00000006
HP Pavilion dv7-6c95dx Recovery Disc (1 of 3).ISO/1439995506.197590/16/2/00000007

Confirmed on v0.80.7 and current master. Others versions are probably affected too.


Related issues

Copied to rgw - Backport #13513: rgw: value of Swift API's X-Object-Manifest header is not url_decoded during segment look up Resolved

Associated revisions

Revision 69cf0895 (diff)
Added by Radoslaw Zarzynski over 7 years ago

rgw: url_decode values from X-Object-Manifest during GET on Swift DLO.

Fixes: #12728
Signed-off-by: Radoslaw Zarzynski <>

Revision 5e5b5121 (diff)
Added by Radoslaw Zarzynski about 7 years ago

rgw: url_decode values from X-Object-Manifest during GET on Swift DLO.

Fixes: #12728
Signed-off-by: Radoslaw Zarzynski <>
(cherry picked from commit 69cf089596a0e5d4da2826b5c276306316a00690)

History

#1 Updated by Radoslaw Zarzynski over 7 years ago

  • Status changed from New to In Progress

#2 Updated by Radoslaw Zarzynski over 7 years ago

  • Status changed from In Progress to Fix Under Review

#3 Updated by Yehuda Sadeh over 7 years ago

  • Backport set to hammer

#4 Updated by Loïc Dachary about 7 years ago

  • Status changed from Fix Under Review to Pending Backport

#5 Updated by Nathan Cutler almost 7 years ago

  • Status changed from Pending Backport to Resolved

Also available in: Atom PDF