Meeting 1


ASU Hacking Club.

Meeting 1

Four challenges from our first meeting of the semester, in order of difficulty.

Everything you need is on the box. Each challenge runs as root and guards /flag. The first three leave their source in /challenge for you to read; the last one hands you a binary and nothing else. Find the assumption each program makes about your input, and break it.

Challenges

  • Challenge 1: A hash is not a lock. It only tells you when you have the key.
  • Challenge 2: The key really is random. It is also shorter than the flag.
  • The Wheel: Three free spins, then call the next three. Luck is not the path.
  • High Score: Two bugs, one leak and one eight-byte write. You need both.

Stuck? Ask in the club Discord.



Challenges

Challenge 1

A lock that nobody cut a key for. It takes 26 bytes on stdin, runs them through SHA-256, and compares the digest against a constant it was built with. Match it and it hands you the flag.

SHA-256 does not run backwards, so the digest is not the answer -- it only tells you when you have found it. Nothing here needs reversing. You already have what you need; the slides below are where it came from.

The flag is at /flag. Only root can read it.

Connect to the challenge by running /challenge/run.

Slides from the meeting: ASU Hacking Club - Meeting 1

Challenge 2

A machine that is very proud of its key. Ten bytes straight out of the kernel's entropy pool, fresh on every run, never printed. It XORs the flag with that key and hands you the result in hex.

The key really is random -- that is not where this goes wrong. The giveaway is that you know more about the plaintext than the program assumes you do, and the key is shorter than what it is hiding.

The flag is at /flag. Only root can read it.

Connect to the challenge by running /challenge/run.

Challenge 3: The Wheel

A slot cabinet with eight symbols on three reels. She reseeds herself every time the cabinet powers on, so the house swears there is nothing to memorise.

You get three free spins to watch her run. Then you have to call the next three spins in a row, exactly, before they happen. Miss one and the night is over — but you can always start a new session.

Guessing blind is 1 in 8^9. That is not the path.

The source is on the box at /challenge/run. Read what the machine uses to seed itself, then ask yourself how many values that could possibly be.

The flag is at /flag. Only root can read it.

Run the challenge with /challenge/run.

Challenge 4: High Score

An arcade high-score board. You can leave a message in the guestbook, or submit a score. Neither is as careful as it looks.

There are two bugs. One hands you something you are not supposed to see, and the other lets you write eight bytes anywhere you like. Neither is enough on its own — you need both, in the right order.

No source this time. The binary is built on the box at start and is not stripped, so the symbols are there to read.

One thing for free, because it is a dead end and not a lesson: the overflow stops short of the saved return address, so there is no ret2win here. The single eight-byte write is the whole primitive. Spend it well, and look for a call that happens after the function you are in returns.

The flag is at /flag. Only root can read it.

Run the challenge with /challenge/highscore.


30-Day Scoreboard:

This scoreboard reflects solves for challenges in this module after the module launched in this dojo.

Rank Hacker Badges Score