diff --git a/jenkins/exposedui/Dockerfile b/jenkins/exposedui/Dockerfile new file mode 100644 index 00000000..b6bd3755 --- /dev/null +++ b/jenkins/exposedui/Dockerfile @@ -0,0 +1,13 @@ +FROM jenkins/jenkins:2.562 + +# Switch to root to modify files if needed +USER root + +# Copy your custom config.xml into Jenkins home +COPY config.xml /var/jenkins_home/config.xml + +# Fix permissions (important!) +RUN chown jenkins:jenkins /var/jenkins_home/config.xml + +# Switch back to Jenkins user +USER jenkins diff --git a/jenkins/exposedui/README.md b/jenkins/exposedui/README.md new file mode 100644 index 00000000..ef114dd7 --- /dev/null +++ b/jenkins/exposedui/README.md @@ -0,0 +1,40 @@ +# Jenkins Exposed UI + +This testbed creates two Jenkins 2.562 instances, one with the setup wizard disabled and anyone allowed to do anything (http://localhost:8081/), and one with default config (http://localhost:8082/). + +The default config, with the setup screen, requires a password which is output to the terminal on first boot, and allows configuring authentication during setup (or makes a default admin user with the same password). + +## Confirming the vulnerability + +``` +docker compose up +``` + +### Vulnerable +``` +curl http://localhost:8081/ +``` + +``` +... +