Skip to content

Restrict path traversal level 1 file access - #225

Open
r1kka6 wants to merge 1 commit into
OWASP-CTF:dc34-ctffrom
r1kka6:fix/path-traversal-level-1
Open

r1kka6 wants to merge 1 commit into
OWASP-CTF:dc34-ctffrom
r1kka6:fix/path-traversal-level-1

Conversation

@r1kka6

@r1kka6 r1kka6 commented Aug 10, 2026

Copy link
Copy Markdown

Summary

  • require Level 1 file names to match the existing allowed file list exactly
  • block direct secret-file reads and ../ traversal into adjacent resource directories
  • update the Level 1 unit test to assert secure rejection of disallowed file names

Verification

  • ./gradlew compileJava test spotlessJavaCheck bootJar --no-daemon passed in an eclipse-temurin:17-jdk container
  • vulnerable baseline returns secret.json content and ../JWT/SymmetricAlgoKeys.json content
  • patched runtime returns isValid=false for both while UserInfo.json remains readable

Signed-off-by: snow <snow@snows-MacBook-Pro-2.local>
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