Wizard Takeover ATO ( IDOR + CSRF )
Plataforma ficticia de memoriales para mascotas. El wizard de creación de 5 pasos se puede secuestrar anónimamente combinando IDs enumerables + ausencia de session binding + un token CSRF que el backend acepta literal (`"csrf-token"`). El atacante toma control del memorial, lee datos privados y recupera la flag
$1,500
That's what a company paid for this bug on YesWeHack. Here it is, rebuilt for you to find it yourself.
Learn to find this bug
This bug paid $1,500 on YesWeHack.
Create your account and practice real bugs that got paid. Download the environment, find it and learn the exact technique — your path to your first bounty.
hunters training
labs from real hacks
completions
paid out for these bugs
Access to all labs · no commitment · cancel anytime
Hackers who solved it· 8
Objectives
Achievement you'll earn
Solve this lab to unlock this shareable achievement

Community writeups
The checklist I run on every new target
47 checks ordered by cost: first what can get you in trouble, then the cheap stuff, and finally the expensive stuff — which is where the big bounties are. I'll send it to your inbox right now.
Unsubscribe in one click, from any email.
Descripción del lab
PetMemoria es una plataforma SaaS ficticia donde los usuarios crean memoriales online
para sus mascotas fallecidas. La página pública muestra una galería de memoriales
publicados y permite crear uno propio a través de un wizard de 5 pasos:
- Paso 1: nombre, especie, raza.
- Paso 2: fechas de nacimiento/fallecimiento, foto preset.
- Paso 3: descripción / mensaje de despedida.
- Paso 4: rasgos de personalidad (chips multi-select), recuerdo favorito.
- Paso 5: email del dueño → recibe un link de edición para gestionar el memorial.
Para reducir la fricción ("permitimos retomar desde otro dispositivo sin login"), el
wizard no exige sesión y los IDs se incrementan en /wizard/{id}/step/N. El form
del paso 5 incluye un token CSRF que se renderiza con Stimulus en el frontend — pero
el backend nunca recibe el valor renderizado y acepta el string literal del placeholder.
Hay además un bot que crea memoriales pendientes cada ~20 segundos para dar vida al
lab. De vez en cuando, el bot crea un memorial llamado "Luna" que contiene la flag en
su campo favorite_memory. Como el memorial está en draft, no aparece en la galería
pública — pero sí se puede encontrar enumerando los IDs.
Cómo verificar
./autodeploy.sh deploy
python3 tests/verify.py # 8/8 checks
python3 exploit.py # captura la flag, exit 0
bash flag/verify.sh # reproduce el md5
Flag
$ bash flag/verify.sh
preimage: petmemoria::luna::wizard_takeover::ywh_souvenirdesanimaux::2026
md5 : a808b4e95a1e9412f6c0ef0255ff65d7
flag : FLAG{a808b4e95a1e9412f6c0ef0255ff65d7}
[OK] La flag esperada coincide.
Referencias
- Reporte original anonimizado: souvenirdesanimaux.fr (YesWeHack disclosure).
- CWE-352: https://cwe.mitre.org/data/definitions/352.html
- CWE-639: https://cwe.mitre.org/data/definitions/639.html
- CWE-287: https://cwe.mitre.org/data/definitions/287.html
- OWASP A01:2021 — Broken Access Control.
