-
Notifications
You must be signed in to change notification settings - Fork 48
H2 cookie header field #219
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
Conversation
source/h2_decoder.c
Outdated
| return AWS_OP_ERR; | ||
| } | ||
|
|
||
| if (decoder->header_block_in_progress.cookies.len) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
don't flush the cookie if the header block is malformed. Once we detect the header block is malformed we stop delivering individual headers.
That behavior would be more clear if we also moved the s_flush_pseudoheaders() call inside the if (!malformed) block. I thought it was simpler-looking to have that function do its own check, but it's obviously more confusing then helpful
source/h2_decoder.c
Outdated
| return AWS_OP_SUCCESS; | ||
| } | ||
| struct aws_http_header concatenated_cookie; | ||
| concatenated_cookie.name = aws_byte_cursor_from_c_str("cookie"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
trivial: = AWS_BYTE_CUR_INIT_FROM_STRING_LITERAL("cookie");
compile-time strlen()
Issue #, if available:
Description of changes:
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.