Skip to content

Restrict file inclusion in low security level - #283

Open
r1kka6 wants to merge 1 commit into
OWASP-CTF:dc34-ctffrom
r1kka6:fix/file-inclusion-low
Open

r1kka6 wants to merge 1 commit into
OWASP-CTF:dc34-ctffrom
r1kka6:fix/file-inclusion-low

Conversation

@r1kka6

@r1kka6 r1kka6 commented Aug 9, 2026

Copy link
Copy Markdown

Summary

  • allow only the built-in challenge pages in the low-level file inclusion handler
  • reject arbitrary local paths before the shared include() sink is reached

Verification

  • docker run --rm -v "$PWD":/work -w /work php:8.3-cli php -l vulnerabilities/fi/source/low.php
  • vulnerable baseline renders /etc/passwd for page=/etc/passwd
  • patched runtime returns ERROR: File not found! for the same payload and still serves page=include.php

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.

1 participant