Skip to content

fix: tighten HTTP/1.1 request handling in the server#18

Merged
ruoka merged 2 commits into
masterfrom
fix/http-1.1-compat-quick-wins
Jul 16, 2026
Merged

fix: tighten HTTP/1.1 request handling in the server#18
ruoka merged 2 commits into
masterfrom
fix/http-1.1-compat-quick-wins

Conversation

@ruoka

@ruoka ruoka commented Jul 16, 2026

Copy link
Copy Markdown
Owner

Summary

  • Require Host on HTTP/1.1 requests; reject missing/empty with 400 and Connection: close
  • Fail closed on invalid/negative Content-Length and incomplete bodies (no handler dispatch)
  • Echo Connection: keep-alive|close on success/404; honor client close
  • Use HTTP/1.1 on error responses (was HTTP/1.0)

Test plan

  • ./tools/CB.sh debug test --jsonl=failures --tags='\[net\]' (419/419)

Made with Cursor

ruoka and others added 2 commits July 16, 2026 16:36
Require Host, fail closed on bad or incomplete bodies, echo Connection,
and answer errors with HTTP/1.1 instead of HTTP/1.0.

Co-authored-by: Cursor <cursoragent@cursor.com>
Use C++ alternative tokens for boolean operators across net sources
and tests; leave != and move references unchanged.

Co-authored-by: Cursor <cursoragent@cursor.com>
@ruoka
ruoka merged commit e5a5267 into master Jul 16, 2026
4 checks passed
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.

1 participant