going brrrrrr
So, one of the first thing that we need when dealing with reverse engineering are tools. Can't do much without them!
Some of the tools that I like to use are:
Kali Linux (Yes, I'm counting it as a tool as much as an Operating System. Live with it :) )
Radare2 and its family
Ghidra
Those are my main tools for reversing a binary. So, lets get them installed onto our machine. -> I've covered how to install these tools here
Other tools that I haven't used, but you may be familiar with them are:
IDA (Pro)
Hopper
dnSpy
Ollydbg
Binary Ninja
And many more that I haven't heard of!
Once we've got everything set up, we're good to go!
Bruteforce but smart
Angr is a powerful binary analysis framework which has come in handy several times in CTFs. It does a huge amount of stuff, so I'm only going to cover the few things I've used it for.
Angr can analyse binaries by inputting 'symbols' rather than literal text. What happens to these symbols (comparisons, transformations) is then recorded, allowing us to get a picture of what a binary is doing. The main usage I've gotten out of this is flag-checker challenges, where we are expected to enter a flag, our input goes through a series of transformations, and is compared against a constant to check if the entered value is correct. Here's a script I used to solve Beginner from Google CTF 2020.
This particular example isn't great, as it is basically a brute force, as I was just getting to learn angr. However, it shows how easy it makes it for challenges with light brute forcing.
Here's a better example: Beginner Rev from Fword CTF
This is a much more intelligent way of exploring the binary, and printed 1755121917194838
after only 20 seconds.