Statically linked code is not removed when decompiling through the IDA plugin
@PeterMatula is already working on this.
Since Sep 16, 2019.
Assessment
This issue has not been assessed yet.
Description
When the attached PE binary file is decompiled through the IDA plugin, statically linked code is not removed, but when I decompile it directly through decompile.sh, it is removed.
Input and output files
The input and both output C files can be downloaded here.
Steps to reproduce
- Decompile the input binary file
hello-world.exethrough the IDA plugin viarun-ida-decompilation.sh:$ run-ida-decompilation.sh hello-world.exe -o hello-world.idpalugin.c - Decompile the same file directly through
decompile.sh:$ decompile.sh hello-world.exe -o hello-world.decompile-sh.c
Expected output
The input binary file hello-world.exe contains just main() with printf("Hello, world!");. This is exactly what decompile.sh produces in hello-world.decompile-sh.c (just a single main() function and nothing more).
However, hello-world.idaplugin.c contains not only _main() but also 47 other functions that come from statically linked code. I would expect them to be removed, just like when the file is decompiled directly through decompile.sh.
Configuration
retdeccommit:8c4b23d(currentmaster)retdec-idaplugincommit: e249927a86c4ebd3b8d5c19de72cdf9f364bef3d (currentmaster)- 64b Arch Linux, GCC 7.2.1, Debug builds of both RetDec and IDA plugin
- Dominant language
- C++
- Stars
- 799
- Forks
- 132
- PR merge metrics
- No merged PRs in 30d
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from avast/retdec-idaplugin
-
Difficulty 5/5 Over a week Newbie friendliness 20/100
avast/retdec-idaplugin#78 · 1 comment ·
-
Difficulty 4/5 3-5 days Newbie friendliness 25/100
avast/retdec-idaplugin#77 ·
-
Difficulty 4/5 3-5 days Newbie friendliness 25/100
avast/retdec-idaplugin#76 · 1 comment ·
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
avast/retdec-idaplugin#75 · 2 comments ·
-
Difficulty 4/5 3-5 days Newbie friendliness 25/100
avast/retdec-idaplugin#74 · 1 comment · 1 reaction ·
All issues in avast/retdec-idaplugin
Similar issues
-
artifact:simulation-scenario domain:physics good first issue help wanted role:validation testing
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Maintainers usually reply within 3 days
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
moneymanagerex/moneymanagerex#8600 · 1 comment ·
Maintainers usually reply within 4 days
-
bug
Difficulty 1/5 Under an hour Newbie friendliness 88/100
NVIDIA/accelerated-computing-hub#294 ·
Maintainers usually reply within 4 days