Recovering Symbols from a Stripped Binary in IDA
How do you get useful symbol names back after a binary has been stripped? There is no perfect answer yet. The same source can produce different machine code depending on the compiler, optimization settings, CPU instructions, and target architecture. Unreferenced static-library code may not be included at all. Here are three approaches I have looked at.
FLAIR
Pros: It is officially supported and straightforward to use.
Cons: Its scope is static system libraries such as libc. It relies on function signatures, and conflicts need to be resolved by hand.
FLAIR comes with IDA 7.7. If it is missing from your installation, there are many guides online for setting it up.
https://github.com/mandiant/flare-ida
The limitation is that a signature may match more than one stripped library function, so a match is not always a definitive identification.
RIZZO
RIZZO compares binary bytes and adds call-graph and constant searches alongside function signatures. That broader set of clues makes it look promising.
Each clue has its own weakness. Signatures can collide; inlining can remove the call relationships a graph relies on; and a quick constant search cannot help much when a function has few constants. Optimization can change the constants too—for example, replacing div 3 with a sequence involving magic numbers.
https://github.com/grayhatacademy/ida/tree/master/plugins/rizzo
Bindiff
BinDiff takes a binary-comparison approach and, according to my assessment, works better than RIZZO. The tradeoff is weaker matching across different optimization settings or instruction sets. It integrates with IDA Pro and also provides a command-line interface.