Skip to content

fix(exposures): add negative html matcher to laravel-env (False Positive)#15598

Merged
theamanrawat merged 3 commits intoprojectdiscovery:mainfrom
vatsalgargg:fix-laravel-env-fp
Mar 16, 2026
Merged

fix(exposures): add negative html matcher to laravel-env (False Positive)#15598
theamanrawat merged 3 commits intoprojectdiscovery:mainfrom
vatsalgargg:fix-laravel-env-fp

Conversation

@vatsalgargg
Copy link
Copy Markdown
Contributor

Description

This PR resolves a false positive in the laravel-env.yaml template. The previous logic was vulnerable to soft 404s and developer blogs where .env configurations were discussed in the HTML body.

Added a negative matcher for text/html in the header to ensure the template only triggers on actual raw environment files.

@neo-by-projectdiscovery-dev
Copy link
Copy Markdown

neo-by-projectdiscovery-dev bot commented Mar 13, 2026

Neo - Nuclei Template Review

No security issues found

2 issues fixed in this PR

Highlights

  • Fixed YAML structure by properly indenting matchers-condition directive
  • Replaced generic header matcher with specific DSL check on content_type variable
  • Template now correctly filters HTML responses to prevent false positives from soft 404s and blog posts
Hardening Notes
  • Consider adding a DSL matcher to verify minimum body length (e.g., 'len(body) > 50') to further reduce false positives from empty or minimal responses
  • The template could benefit from checking for additional Laravel-specific patterns like 'MAIL_MAILER=' or 'SESSION_DRIVER=' in the regex matcher to increase detection confidence

Comment @pdneo help for available commands. · Open in Neo

@pussycat0x pussycat0x added the Done Ready to merge label Mar 15, 2026
@theamanrawat theamanrawat merged commit 3632908 into projectdiscovery:main Mar 16, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Done Ready to merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants