Reverse › Module 4 › Lesson 4
Lab — Formats
Pack ELF, PE, and sections/symbols triage — one Linux toy and one approved crackme on $RE_LAB.
Visual · re_format_lab
Lab: format pack. $RE_LAB only. Original Cyberlium.
Opening
Format pack ties headers to the disassembly you will refine in static tools module.
Lessons 4-1–4-3 covered ELF, PE, and symbols. This lab merges triage sheets for YOUR Linux toy and one approved crackme (ELF or PE) inside $RE_LAB — headers, entry, key sections, symbol/import shortlist. No commercial unauthorized binaries. Next: Quiz — File Formats.
1. Lab contract: format pack
Create $HOME/cyberlium-lab/t23-m04-l04-format-lab.txt merging ELF triage, PE triage (if applicable), sections/symbols shortlist, and sha256 for each target.
Optional: side-by-side note on ELF vs PE field names for entry and code sections.
Command guide
Try these commands — Lab contract: format pack
═══ TOOLS & WEBSITES ═══ Browse / read these (authorized learning only — stay in YOUR lab / program scope)
ELF sections — https://man7.org/linux/man-pages/man5/elf.5.html objdump -h — https://man7.org/linux/man-pages/man1/objdump.1.html (section headers) Binary Ninja — https://docs.binary.ninja/ (sections/symbols in GUI literacy)
═══ INSTALL ═══
Linux (Debian/Ubuntu):
Command — copy this
sudo apt install binutils
macOS:
Command — copy this
brew install binutils
Built-in or brew install binutils Built-in (Xcode CLI) or brew install binutils
Windows: Use WSL binutils
═══ LINUX / macOS ═══
Command — copy this
export LAB_RE=${LAB_RE:-$HOME/cyberlium-lab/t23-re}
readelf -S "$LAB_RE/bin/check" | grep -E '\.text|\.rodata|\.data|\.bss|symtab|strtab'
objdump -h "$LAB_RE/bin/check"
nm -C "$LAB_RE/bin/check" | head -15
readelf -s "$LAB_RE/bin/check" | wc -l═══ WINDOWS ═══
Command — copy this
Get-Content $HOME/cyberlium-lab/t23-re/roe.txt | Select-String never
Primary tools to practice this lesson: readelf, nm, objdump. Reference sites: ELF sections (https://man7.org/linux/man-pages/man5/elf.5.html); objdump -h (https://man7.org/linux/man-pages/man1/objdump.1.html); Binary Ninja (https://docs.binary.ninja/). Run every command in the box — install first, then the usage lines — only on YOUR lab / program scope.
2. Cross-check authorization
Both targets must be YOUR toy or approved crackme/CTF — grep notes for warez or commercial paths and remove.
Update sha256 if you rebuild toy binary.
3. Lock the proof
chmod 600 on the pack. Quiz next — then Static RE Tools.
Format literacy feeds objdump/Ghidra workflows in M5.
4. What you ship: file format literacy pack for $RE_LAB
ELF + PE/symbols triage merged. Two authorized targets with sha256. $RE_LAB named. chmod 600.
5. What you record before the next lesson
Date. Format pack path. $RE_LAB named. File t23-m04-l04-format-lab.txt chmod 600.
6. Wrong vs right: commercial piracy vs crackmes/CTF toys
Worked failure — same MSF word, opposite target. Right never needs a café Wi-Fi or classmate laptop.
Wrong
Include triage of commercial crack. Skip sha256 on targets.
Right
Write YOUR format pack for $RE_LAB authorized binaries. chmod 600. Next: Quiz — File Formats.
Mission: freeze YOUR format pack
1) Merge M4 triage sections. 2) Log sha256 for each target. 3) chmod 600.
Stuck? Ask Cyberlium AI Mentor
Headers tell you where code starts — disassembly follows.
Knowledge Check
APPLY: This lab requires:
Multiple choice
Knowledge Check
APPLY: True or False: Format pack should log sha256 per target.
True or False
Knowledge Check
APPLY: ELF vs PE triage both should note:
Multiple choice