The 5 Levels of Reverse Engineering
Quick Overview
The video successfully reverse engineers a program across five levels, starting with static analysis of strings (Level 1), moving to static analysis of assembly code (Level 2), then dynamic analysis using GDB (Level 3), symbolic execution with Angr (Level 4), and concluding with finding real bugs in firmware using symbolic execution (Level 5).
Key Points: Level 1 reverse engineering involved using the 'strings' utility on the initial binary to extract human-readable content, revealing error codes and strings like 'bad kitty!' and 'good kitty!'. Level 2 static analysis used 'objdump -d' to disassemble the binary, revealing functions like 'main', 'factorial', and 'pppeuler3', which hinted at the program's logic. Level 3 dynamic analysis utilized GDB to set breakpoints (like at the start of 'main') and observe the program's execution flow and stack contents to manually determine the correct input. Level 4 symbolic execution employed the Angr Python library, setting up a project, defining constraints on the flag input (ASCII characters between 0x20 and 0x7F), and using a solver to find valid inputs. The symbolic execution script identified that the correct input for the 'crack' challenge was '00sGo4M8' by analyzing the program's branches. Level 5 involved extracting firmware from a physical device (a Wi-Fi repeater) and recursively analyzing its contents using 'binwalk -Me' to find executables and configuration files like 'rc.d' scripts. The final analysis of the firmware's startup scripts revealed a service running 'commuos', which was then analyzed to find potential vulnerabilities using symbolic execution.
Context: This video serves as a tutorial demonstrating a five-level progression in reverse engineering a program, starting from basic string extraction to advanced symbolic execution and finally applying these techniques to analyze real-world embedded device firmware. The presenter guides the viewer through each level, progressively revealing more complex techniques.