Skip to content

feat(input): add raw http request input mode - #7629

Open
dogancanbakir wants to merge 2 commits into
devfrom
7590-raw-http-input
Open

feat(input): add raw http request input mode#7629
dogancanbakir wants to merge 2 commits into
devfrom
7590-raw-http-input

Conversation

@dogancanbakir

@dogancanbakir dogancanbakir commented Jul 31, 2026

Copy link
Copy Markdown
Member

Closes #7628
Sub-task of #7590

Depends on #7627 and carries its commit, so merge that one first. ParseRawRequest needs the absolute request target fix from it for the absolute form below.

Fuzzing takes the request shape from the input, so a bare URL is always fuzzed as a GET. Anything else needed a spec, captured traffic, or a hand-written proxify document. -im http reads requests as they appear on the wire, which is what Burp and browser devtools already put on the clipboard:

POST /api/login HTTP/1.1
Host: example.com
Content-Type: application/json

{"user":"admin","pass":"secret"}
nuclei -l login.http -im http -dast -t fuzzing-templates/
  • multiple requests separated by a line starting with ###, the .http file convention
  • an absolute request target (POST https://example.com/api/login HTTP/1.1) states the scheme, otherwise it is inferred from the authority by reusing DetermineSchemeOrder rather than adding a second heuristic
  • tolerates a paste that ends at the last header
  • a request with no Host header and no absolute target is skipped with a warning, matching how the other formats report unusable entries

Docs in pkg/input/README.md cover which -im mode to reach for and the shortest path from one endpoint to -dast. The -im list in the READMEs is refreshed.

Unit tests cover parsing, separators, scheme resolution and skipping. Integration coverage is fuzz/fuzz-raw-http-input.yaml, which seeds a base request from a raw file and fuzzes a JSON body end to end. Full integration suite is green.

The second line was always consumed as the Host line, so any request-shaped
input whose Host header sat elsewhere lost that header silently and skipped
fuzzing. Reading values by skipping one byte past the colon also truncated
unspaced values and panicked on valueless headers, crashing the scan. Absolute
request targets, as used by proxy captures, were appended to the authority
instead of replacing it.
Fuzzing takes the request shape from the input, so a bare URL is always fuzzed
as a GET and anything else needed a spec, captured traffic or a hand-written
proxify document. -im http reads requests as they appear on the wire, which is
what Burp and browser devtools already put on the clipboard.
@coderabbitai

coderabbitai Bot commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: ab4271e4-ded8-41ae-ae7a-9e92566ca197

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Comment @coderabbitai help to get the list of available commands.

@dogancanbakir
dogancanbakir requested a review from Mzack9999 July 31, 2026 12:40
@dogancanbakir dogancanbakir self-assigned this Jul 31, 2026
@dogancanbakir
dogancanbakir changed the base branch from 7626-raw-request-parsing to dev July 31, 2026 12:43
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.

Add raw HTTP request input mode (-im http) for DAST base requests

2 participants