mandiant / GoReSym

Go symbol recovery tool
MIT License
498 stars 62 forks source link

Add command line flag to skip extracting functions #49

Open pombredanne opened 5 months ago

pombredanne commented 5 months ago

When I analyse Go binaries, I often want to have a quick first look at the buildinfo and files without looking at all the function details. I would awesome to have a command line flag that would skip collecting the function details, basically a conditional on this https://github.com/mandiant/GoReSym/blob/d75fbb44e72d1c470e90042e7da2321e61a91403/main.go#L289 that would be true by default (so that the behavior is not changed) and the CLI flag would skip/exclude the UserFunctions and StdFunctions sections.

Can I interest you in a patch for this? This would be a very simple update.

stevemk14ebr commented 5 months ago

A patch like this would be fine, as long as it default to true and doesn't interfere with the actual symbol recovery logic. The proposed change here is how I would do it, the recovery still needs to occur to ensure the correct pclntab candidate is chosen, but then we can ignore displaying that info depending on the provided flag.

I say go for it