Aller au contenu

basic-file-exploit

Writeup de Arnold-26, repris avec son autorisation. Source : cylab-academy-writeups — challenge #252, résolu le 2026-11-23. Flags tronqués.

Catégorie : Binary Exploitation · Challenge : #252 · Résolu le : 2026-11-23

Énoncé

The program provided allows you to write to a file and read what you wrote from it. Try playing around with it and see if you can break it!

The program's source code with the flag redacted can be downloaded here.

Résolution

Méthode : entrée 0 -> puts(flag).

Après avoir stocke une entrée, data_read() compare strtol(entry, NULL, 10) == 0 : demander l'entrée 0 affiche directement le flag.

Flag

academy{...}