Goal Reached Thanks to every supporter — we hit 100%!

Goal: 1000 CNY · Raised: 1000 CNY

100.0%

CVE-2025-29927 PoC — Authorization Bypass in Next.js Middleware

Source
Associated Vulnerability
Title:Authorization Bypass in Next.js Middleware (CVE-2025-29927)
Description:Next.js is a React framework for building full-stack web applications. Starting in version 1.11.4 and prior to versions 12.3.5, 13.5.9, 14.2.25, and 15.2.3, it is possible to bypass authorization checks within a Next.js application, if the authorization check occurs in middleware. If patching to a safe version is infeasible, it is recommend that you prevent external user requests which contain the x-middleware-subrequest header from reaching your Next.js application. This vulnerability is fixed in 12.3.5, 13.5.9, 14.2.25, and 15.2.3.
Description
Una CTF, in formato DSP-compliant, basata sulla CVE-2025-29927 di nextjs.
Readme

-----

# 🚩 Vuln Gallery CTF

 Benvenuto a **Vuln Gallery**, una CTF (Capture The Flag) di livello intermedio basata su Linux.

Questa sfida ti guiderà dall'exploit iniziale di un'applicazione web moderna fino alla privilege escalation su un sistema Linux mal configurato. La tua missione è sfruttare le vulnerabilità, muoverti lateralmente nel sistema e ottenere il controllo completo.

-----

## 🚀 Come Giocare

Questo progetto utilizza Docker e Docker Compose per una configurazione rapida e consistente. Devi solo averli installati.

1.  **Clona questo repository** (o scarica il file zip della cartella `player-deploy`).

2.  **Apri un terminale** e naviga nella directory `player-deploy`:

    ```bash
    cd player-deploy
    ```

3.  **Avvia la macchina** in background con il seguente comando:

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

    Docker scaricherà l'immagine della macchina e la avvierà.

-----

## 🎯 Il Tuo Bersaglio

La macchina della CTF è ora in esecuzione e raggiungibile al seguente indirizzo IP statico:

## 172.20.0.10

Inizia la tua fase di ricognizione da qui.

-----

## 🏁 Obiettivi

Il tuo scopo è trovare e leggere due flag nel sistema:

1.  **`user.txt`**: Ottieni l'accesso come utente.
2.  **`root.txt`**: Scala i tuoi privilegi fino a `root`.

-----

## 🧹 Pulizia

Quando hai finito, puoi fermare e rimuovere il container con un singolo comando dalla directory `player-deploy`:

```bash
docker-compose down
```

-----

### ⚠️ Disclaimer

Questa macchina è stata progettata per scopi educativi e di training sulla sicurezza informatica. Tutte le vulnerabilità sono intenzionali. Per favore, eseguila in un ambiente di rete isolato.

Buona caccia e divertiti a hackerare\! 🕵️‍♂️
File Snapshot

[4.0K] /data/pocs/7c026cec19662cba793e57875833e2d12c088f9d ├── [ 152] docker-compose.yml ├── [2.5K] Dockerfile ├── [918K] Network_Security_Rinaldi.pdf ├── [4.0K] nextjs-app │   ├── [4.0K] app │   │   ├── [4.0K] admin │   │   │   └── [8.0K] page.tsx │   │   ├── [4.0K] api │   │   │   ├── [4.0K] auth │   │   │   │   ├── [4.0K] login │   │   │   │   │   └── [ 716] route.ts │   │   │   │   ├── [4.0K] logout │   │   │   │   │   └── [ 224] route.ts │   │   │   │   └── [4.0K] user │   │   │   │   └── [ 546] route.ts │   │   │   ├── [4.0K] download │   │   │   │   └── [1.7K] route.ts │   │   │   ├── [4.0K] images │   │   │   │   └── [ 332] route.ts │   │   │   ├── [4.0K] register │   │   │   │   └── [ 475] route.ts │   │   │   ├── [4.0K] transform │   │   │   │   └── [2.4K] route.ts │   │   │   └── [4.0K] upload │   │   │   └── [2.4K] route.ts │   │   ├── [4.0K] components │   │   │   └── [2.4K] AuthNav.tsx │   │   ├── [ 25K] favicon.ico │   │   ├── [4.0K] gallery │   │   │   └── [6.0K] page.tsx │   │   ├── [1.7K] globals.css │   │   ├── [2.5K] layout.tsx │   │   ├── [4.0K] lib │   │   │   ├── [1.3K] auth.ts │   │   │   ├── [ 520] db.ts │   │   │   ├── [ 92] declares.ts │   │   │   └── [1.3K] users.ts │   │   ├── [4.0K] login │   │   │   └── [3.3K] page.tsx │   │   ├── [5.5K] page.tsx │   │   ├── [4.0K] register │   │   │   └── [2.8K] page.tsx │   │   ├── [4.0K] upload │   │   │   └── [ 11K] page.tsx │   │   └── [4.0K] utils │   │   └── [ 793] jwt.ts │   ├── [1.3K] middleware.ts │   ├── [ 141] next.config.ts │   ├── [ 774] package.json │   ├── [ 76K] package-lock.json │   ├── [ 81] postcss.config.mjs │   ├── [4.0K] public │   │   ├── [ 391] file.svg │   │   ├── [1.0K] globe.svg │   │   ├── [4.0K] images │   │   │   ├── [ 34K] github.jpg │   │   │   ├── [ 85K] hackademy.jpg │   │   │   └── [ 78K] spr.jpg │   │   ├── [1.3K] next.svg │   │   ├── [ 128] vercel.svg │   │   └── [ 385] window.svg │   ├── [1.4K] README.md │   └── [ 598] tsconfig.json ├── [4.0K] player-deploy │   └── [ 285] docker-compose.yml ├── [1.7K] README.md └── [4.0K] scripts ├── [4.0K] backup │   └── [ 560] database_backup.aes ├── [ 216] entrypoint.sh └── [4.0K] privesc ├── [ 832] log_archiver.py └── [ 380] wrapper.c 27 directories, 47 files
Shenlong Bot has cached this for you
Remarks
    1. It is advised to access via the original source first.
    2. Local POC snapshots are reserved for subscribers — if the original source is unavailable, the local mirror is part of the paid plan.
    3. Mirroring, verifying, and maintaining this POC archive takes ongoing effort, so local snapshots are a paid feature. Your subscription keeps the archive online — thank you for the support. View subscription plans →