Skip to content
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

[FALSE-POSITIVE] Next.js - Cache Poisoning - Headers #11473

Open
DShelef opened this issue Jan 11, 2025 · 0 comments
Open

[FALSE-POSITIVE] Next.js - Cache Poisoning - Headers #11473

DShelef opened this issue Jan 11, 2025 · 0 comments
Assignees
Labels
false-positive Nuclei template reporting invalid/unexpected result

Comments

@DShelef
Copy link

DShelef commented Jan 11, 2025

Template IDs or paths

- http/vulnerabilities/nextjs/nextjs-rsc-cache.yaml

Environment

Not relevant

Steps To Reproduce

Run nuclei -t http/vulnerabilities/nextjs/nextjs-rsc-cache.yaml -u <WEBAPP>

Relevant dumped responses

HTTP/1.1 200 OK
Connection: close
Content-Length: 2
Cache-Control: max-age=0, no-cache, no-store
Date: Mon, 09 Dec 2024 21:38:51 GMT
Expires: Mon, 09 Dec 2024 21:38:51 GMT
Pragma: no-cache
Strict-Transport-Security: max-age=15552000; includeSubDomains;
X-Content-Type-Options: nosniff
X-Matched-Path: /
X-Middleware-Skip: 1

{}

Anything else?

The issue was reported by nuclei even though the webapp isn't vulnerable.

According to the the reference in the template (link) "Since version 13.4.20-canary.13, Next.js has added cache-control to SSR responses to prevent them from being cached". As you can see in the dumped response above, the header cache-control was added and even Pargma: no-cache was added. None of them is checked for in the template.

Couldn't see an open PR for that one or an open issue, so I open this one. Checking for the either of the headers' existence would resolve the problem I believe. Hope I haven't missed anything crucial.

@DShelef DShelef added the false-positive Nuclei template reporting invalid/unexpected result label Jan 11, 2025
@DShelef DShelef changed the title [FALSE-POSITIVE] ... [FALSE-POSITIVE] Next.js - Cache Poisoning - Headers Jan 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
false-positive Nuclei template reporting invalid/unexpected result
Projects
None yet
Development

No branches or pull requests

2 participants