versioned_writes middleware is mis-placed in proxy pipeline
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Object Storage (swift) |
Fix Released
|
Undecided
|
Alistair Coles |
Bug Description
Updated description:
When versioned_writes is not explicitly configured in the proxy pipeline and *LO middlewares *are* configured, then the versioned_writes middleware gets inserted to the left of DLO, which is incorrect and causes the following incorrect behaviour to manifest...
Original description:
When an SLO manifest A in a versioned container is overwritten by object B, the manifest A is resolved and the assembled large object is copied to the versions container. The original manifest is lost. Then when the object B in the versioned container is deleted, it is replaced with the large object, not the original manifest.
To reproduce:
#create containers, segment and manifest...
% curl -H 'X-Auth-Token: AUTH_tk5a7c8aa2
% curl -H 'X-Auth-Token: AUTH_tk5a7c8aa2
% curl -H 'X-Auth-Token: AUTH_tk5a7c8aa2
% curl -H 'X-Auth-Token: AUTH_tk5a7c8aa2
% curl -H 'X-Auth-Token: AUTH_tk5a7c8aa2
# sanity check, the versions container is empty and the manifest is a manifest...
% curl -H 'X-Auth-Token: AUTH_tk5a7c8aa2
[]%
% curl -H 'X-Auth-Token: AUTH_tk5a7c8aa2
HTTP/1.1 200 OK
Content-Length: 4194304
Last-Modified: Fri, 22 Jan 2016 12:16:41 GMT
Connection: close
Etag: "a42db41ea9e4a9
X-Timestamp: 1453465000.92552
Date: Fri, 22 Jan 2016 12:17:56 GMT
Content-Type: application/
X-Static-
X-Trans-Id: tx4fb306cefd4b4
# now overwrite the manifest, it doesn't matter what the content is...
% curl -H 'X-Auth-Token: AUTH_tk5a7c8aa2
# oops, now the versions container has 4MB file
% curl -H 'X-Auth-Token: AUTH_tk5a7c8aa2
# and its not just the listing telling us that when really its a manifest, it really is not a manifest...
% curl -H 'X-Auth-Token: AUTH_tk5a7c8aa2
HTTP/1.1 200 OK
Content-Length: 4194304
Accept-Ranges: bytes
Last-Modified: Fri, 22 Jan 2016 12:29:46 GMT
Etag: b5cfa9d6c8febd6
X-Timestamp: 1453465785.36908
Content-Type: application/
X-Trans-Id: tx26f122fcaa204
Date: Fri, 22 Jan 2016 12:30:55 GMT
# now delete the object in the versioned container...
% curl -H 'X-Auth-Token: AUTH_tk5a7c8aa2
# and oops, we now have alare object, not the manifest, copied back
% curl -H 'X-Auth-Token: AUTH_tk5a7c8aa2
HTTP/1.1 200 OK
Content-Length: 4194304
Accept-Ranges: bytes
Last-Modified: Fri, 22 Jan 2016 12:31:09 GMT
Etag: b5cfa9d6c8febd6
X-Timestamp: 1453465868.72903
Content-Type: application/
X-Trans-Id: txd37023de79194
Date: Fri, 22 Jan 2016 12:31:18 GMT
CVE References
Changed in swift: | |
status: | New → In Progress |
summary: |
- SLO manifests become the large object when versioned + versioned_writes middleware is mis-placed in proxy pipeline |
description: | updated |
Changed in swift: | |
assignee: | Janie Richling (jrichli) → Alistair Coles (alistair-coles) |
This is different behaviour than reported here https:/ /bugs.launchpad .net/swift/ +bug/1365862. I cannot reproduce bug 1365862.