-
Notifications
You must be signed in to change notification settings - Fork 182
multi-line (folded) HTTP header wrongly parsed #53
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
Comments
Any comments on this? |
A pull request would help push this through more quickly if there's an issue. |
There's definitely an issue. I'm wondering why you saw this as bogus... |
I didn't say anything about it being bogus. I said a pull request would help it along more quickly if there's an issue. That's still true. |
Okay, there are actually several ways to fix this. First one is to replace every folding by a single SP character. Second one is to keep foldings in the parsing results as they have been brought in. That's why I initially thought it would need a discussion before making a patch for that. |
As a sidenote, I hit this bug in the real-world setup of applications and it wasn't my intention to try to do some nitpicking around a dark corner of the HTTP spec. |
I guess we could try to replace foldings with a space. |
According to RFC2616 2.2., the parsed value of a folded header is supposed to have continuations intact or replaced with a single SP though waitress strips them all (see this).
This behaviour keep developers from dealing with folded headers that are rendered with meaningful occurrences of continuations.
The text was updated successfully, but these errors were encountered: