Skip to content

Request smuggling / desync framing check - #28

Merged
emmanuelgautier merged 1 commit into
mainfrom
feat/request-smuggling
Nov 10, 2026
Merged

emmanuelgautier merged 1 commit into
mainfrom
feat/request-smuggling

Conversation

@emmanuelgautier

Copy link
Copy Markdown
Member

Closes #10.

Adds smuggling.ambiguous_framing, an aggressive-suite check (runs only with --aggressive) that tests the precondition for every classic request-smuggling attack: whether the proxy rejects RFC 9112-violating ambiguous message framing. Introduces a raw sender (smugprobe) since net/http sanitizes malformed framing before it reaches the wire.

It sends four framings and flags any the proxy accepts (2xx/3xx) instead of rejecting (4xx/5xx or dropped connection):

  • conflicting duplicate Content-Length (CL.CL)
  • Content-Length + Transfer-Encoding: chunked (CL.TE / TE.CL)
  • duplicate Transfer-Encoding with a non-chunked final encoding (TE.TE)
  • whitespace-obfuscated header name (Transfer-Encoding : chunked)

Non-destructive: only benign, bounded, self-contained bodies, each on its own Connection: close socket. It never attempts the actual desync (which could poison another client's connection) — it reports purely on accept-vs-reject.

Checklist coverage

  • CL.TE, TE.CL, TE.TE classic variants (framing acceptance tested)
  • Duplicate/conflicting Content-Length or Transfer-Encoding rejection behavior
  • H2.CL / H2.TE on HTTP/2→1.1 downgrade paths — deferred; ties to the HTTP/2 protocol work (HTTP/2 & HTTP/3 Protocol-Specific #13)
  • Raw H2C smuggling — deferred (needs HTTP/2 framing control)
  • Connection-reuse boundary isolation — deferred

Deferred items are documented in docs/checks/smuggling.mdx. Includes registration and a category test (permissive vs. strict raw-server stand-ins).

@emmanuelgautier
emmanuelgautier merged commit dd31b4b into main Nov 10, 2026
4 checks passed
@emmanuelgautier
emmanuelgautier deleted the feat/request-smuggling branch November 10, 2026 00:10
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.

Request Smuggling / Desync

1 participant