utf-8 in metadata and http header names
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Object Storage (swift) |
Fix Released
|
Undecided
|
David Hadas |
Bug Description
RFC2616 implicitly allows transferring utf-8 in headers (vals) but not in header names (keys)
Swift functional tests includes testing for utf-8 header names (keys) which is non aligned with the standard.
This seem to be the case when testing file metadata.
File metadata keys are than transferred as part of the http header keys (header names) as
X-
As a result metadata_keys in swift must be composed from a subset of ASCII characters - alpha numerics, some punctuation, not a lot else* and cannot be utf-8.
Details from the RFC:
message-header = field-name ":" [ field-value ]
field-name = token
field-value = *( field-content | LWS )
field-content = <the OCTETs making up the field-value
Zoom in on field-name (i.e. token)
token = 1*<any CHAR except CTLs or separators>
Zoom on CHAR, CTL and separators:
CHAR = <any US-ASCII character (octets 0 - 127)>
CTL = <any US-ASCII control character
separators = "(" | ")" | "<" | ">" | "@"
| "," | ";" | ":" | "\" | <">
| "/" | "[" | "]" | "?" | "="
| "{" | "}" | SP | HT
* Thanks to Tom Anderson's summary listed in http://
Changed in swift: | |
status: | New → In Progress |
Changed in swift: | |
milestone: | none → 1.7.5 |
status: | Fix Committed → Fix Released |
Typo: X-Object- Meta-<metadata_ key>: <metadata_val>