Lion Cipher Lab

Read ARM64 assembly by cross-compiling your own program, and map what you know from x86-64

Why it matters

ARM64 is no longer exotic. It runs most phones, Apple laptops, a growing share of cloud servers, and a huge range of routers, cameras and other embedded devices. Analysts increasingly receive a program or a firmware image and cannot assume it is for an x86 PC. The good news is that the reading skills transfer: find the arguments, find the branches and loops, find the calls. You only need a new cheat sheet for the registers and instructions. Cross-compiling your own program is the safest way to build that cheat sheet.

What you'll learn

Steps in this lab

  1. Why a second architecture, and how this lab works
  2. Install the cross-compiler and build for ARM64
  3. Make the cheat sheet: registers
  4. Read scale: arithmetic and return
  5. Read biggest: how an if looks on ARM64
  6. Read sum_to and the call: loops, bl and the link register
  7. Disassemble the real program
  8. Run it under emulation, or skip running
  9. Turn the optimiser on and compare architectures
  10. Clean up

Open the full interactive lab →

Keep learning