Skip to content
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

update picohttpparser and reject multiline headers #1933

Merged
merged 7 commits into from Feb 11, 2019

Conversation

i110
Copy link
Contributor

@i110 i110 commented Dec 19, 2018

This PR intends to add the following three changes:

Copy link
Member

@kazuho kazuho left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the PR. LGTM modulo some nit-picking comments. Please let me know what you think.

@@ -265,6 +265,11 @@ static void on_head(h2o_socket_t *sock, const char *err)

/* fill-in the headers */
for (i = 0; i != num_headers; ++i) {
if (src_headers[i].name_len == 0) {
/* reject multiline header */
on_error_before_head(client, "received multiline header that is not allowed");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"line folding of header fields is not supported"?

lib/http1.c Outdated
{
if (body == NULL)
body = "Bad Request";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we consistently specify the body on the call side?

@i110
Copy link
Contributor Author

i110 commented Jan 23, 2019

@kazuho sorry I actually forgot this PR. I addressed the issues in dff08d7 and 473f285.

@i110 i110 force-pushed the i110/header-folding-and-update-phr branch from 6d49b7b to cfdbb3c Compare January 23, 2019 20:51
@kazuho kazuho merged commit 4651438 into master Feb 11, 2019
@kazuho
Copy link
Member

kazuho commented Feb 11, 2019

LGTM!!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants