-
Notifications
You must be signed in to change notification settings - Fork 42
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
field line recombination vs empty field line value #836
Comments
|
It's entirely consistent with the requirements on list value generation (MUST NOT generate empty elements) and parsing (MUST ignore empty elements) in 7230, so no change there. |
? That is about the validation of the number of list elements. We even say below: |
|
It's observable in esoteric cases as also discussed with structured field values (which is why it says what it does), e.g.,: should be equivalent to to account for naïvely-combining intermediaries. |
|
My concern with the new text is that it makes it impossible to detect whether the sender violated the MUST-level requirement. Consider: Under RFC 7230 and 8941, the SF parser would receive "1,,2" (plus whitespace) and then fail parsing. With the new recipient requirement, the parser would receive "1,2" (plus ws) and parse this as a two-element list. That's why I think this is a new requirement (that would need to be documented as such); but I would prefer to get rid of it. (unless I'm missing something) |
"For compatibility with legacy list rules, a recipient MUST parse and ignore a reasonable number of empty list elements" is a recipient requirement that does exactly that. The only way to "parse and ignore" is to exclude empty list elements. |
|
Well. Under that interpretation, we'll need an erratum for RFC 8941, right? |
|
The "for compatibility..." text that Roy mentions in 7230 is specific to the We should back this change out. It's fine for a field to define how empty list elements should be handled (either by the |
|
FWIW, the text was added as part of #557. |
|
In particular, with the current text, these two messages and ...would be treated differently. (wrt layering: field line combination happens at a lower level than "list" processing, right?) |
remove restriction to non-empty lines (fixes #836)
5.2 (https://greenbytes.de/tech/webdav/draft-ietf-httpbis-semantics-latest.html#rfc.section.5.2):
"When a field name is only present once in a section, the combined field value for that field consists of the corresponding field line value. When a field name is repeated within a section, its combined field value consists of the list of corresponding field line values within that section, concatenated in order, with each non-empty field line value separated by a comma."
This seems to be a change from RFC 7230, which says in 3.2.2 (https://greenbytes.de/tech/webdav/rfc7230.html#rfc.section.3.2.2):
"A recipient MAY combine multiple header fields with the same field name into one "field-name: field-value" pair, without changing the semantics of the message, by appending each subsequent field value to the combined field value in order, separated by a comma."
So there's a difference with respect to empty field line values.
Was this change intentional? In that case it needs to be list as change.
I'm asking because RFC 8941 currently is aligned with RFC 7230.
The text was updated successfully, but these errors were encountered: