Narnia Level 8
Narnia Level 8 — a later Narnia level that combines the earlier techniques; use the source and a debugger to find where your input goes.
Table of Contents
Source: This content is aggregated from overthewire (MIT). Visit the original repository for the latest version.
There is no information for this level, intentionally.
Study guide
Level map: logged in as narnia8, find the password for narnia9.
What this level teaches
Choosing the right technique yourself, after seeing several in earlier levels.
Key ideas
- Diagnose first. Ask which memory-safety bug is present before choosing an attack.
- Use the debugger.
gdbshows registers, the stack and memory around your input, which is faster than guessing. - Pointer-based bugs. Programs that copy data through pointers may let a small mistake in one place write somewhere unexpected.
- Keep notes. By now you have a toolbox; write which tool fits which symptom.
How to approach it
- Read the source twice, slowly, and annotate every pointer and buffer.
- Run it under
gdbwith normal input and note what lives where. - Change one thing at a time until the program does something it should not.
Why it matters
Real vulnerability hunting is exactly this: reading code and choosing the right primitive.