chore(deps): bump rawhttp to fix duplicate HTTP status line parsing - #7566
chore(deps): bump rawhttp to fix duplicate HTTP status line parsing#7566lopster568 wants to merge 1 commit into
Conversation
Signed-off-by: Roshan <rosh.s568@gmail.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (1)
WalkthroughUpdates the ChangesRaw HTTP dependency update
Estimated code review effort: 1 (Trivial) | ~2 minutes Suggested reviewers: Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 Checkov (3.3.8)go.modTraceback (most recent call last): Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
No need to bump PD deps manually, especially since it's still untagged. We just tagged the new version (v0.1.91), so just let dependabot pick it up and open the PR when it's ready. No rush. Closing this. |
Proposed changes
Bumps
github.com/projectdiscovery/rawhttpfromv0.1.90tov0.1.91-0.20260616205543-c41b464d9badto pull in the fix for parsing responses with duplicate HTTP status lines.Fixes #7363
Targets that emit a malformed response with a repeated status line before the headers (e.g. a Grandstream HT801 responding with
HTTP/1.0 200 OKtwice) fail with a header parse error even underunsafe: true, so matchers never run and the response body is unreachable. As discussed in #7363, the root cause is inrawhttp: its header reader rejects any line without a colon, and a repeated status line has none. The fix was merged upstream in projectdiscovery/rawhttp#542 (commitc41b464), which skips leading duplicate status lines inReadResponsebefore header parsing, bounded at 8 lines, with regression tests (TestReadResponseDuplicateStatusLines,TestReadResponseTripleStatusLines).No new
rawhttptag has been cut pastv0.1.90yet, so this pins the pseudo-version at the fix merge commit, which is also the currentrawhttpmain HEAD (the only commits betweenv0.1.90and main are the fix PR itself). Same shape as #7464, the govaluate bump pinned to an untagged upstream fix commit.Proof
Standalone repro calling rawhttp's
client.ReadResponseon the response bytes from the issue ("HTTP/1.0 200 OK\r\nHTTP/1.0 200 OK\r\nContent-Type: text/html\r\nContent-Length: 5\r\n\r\nhello"):Before, pinned at
v0.1.90:After, pinned at
v0.1.91-0.20260616205543-c41b464d9bad:Also verified end to end with a local nuclei build at this commit against a mock server replaying the device's response under an
unsafe: trueraw template: the response now parses (-debugshows the 200, headers, and body) and a word matcher on the body fires.Local checks on the changed module graph:
go build ./cmd/nucleipassesgo vet ./pkg/protocols/http/... ./pkg/protocols/common/protocolstate/...(the packages importing rawhttp) passesgo test ./pkg/protocols/http/...passes with the bumpgo mod tidyproduced no changes beyond the bumpNote:
TestExecuteParallelHTTP_GoroutineLeaksis flaky under load on my machine on a cleandevcheckout as well (fastdialercloseAfterTimeoutgoroutine caught by the leak detector), unrelated to this change.Checklist
Summary by CodeRabbit