Skip to content

Validate command injection level 1 IP input - #224

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

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

Conversation

@r1kka6

@r1kka6 r1kka6 commented Aug 10, 2026

Copy link
Copy Markdown

Summary

  • require Level 1 ipaddress values to match the existing IPv4/localhost validator
  • prevent shell metacharacters from reaching the ping command string
  • keep valid 127.0.0.1 and localhost requests behaving as before

Verification

  • ./gradlew compileJava test spotlessJavaCheck bootJar --no-daemon passed in an eclipse-temurin:17-jdk container
  • vulnerable baseline returns CTF_MARKER for ipaddress=127.0.0.1; echo CTF_MARKER
  • patched runtime returns empty content for that payload while valid 127.0.0.1 and localhost still reach the ping path

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