fkie-cad / dewolf

A research decompiler implemented as a Binary Ninja plugin.
GNU Lesser General Public License v2.1
176 stars 9 forks source link

[ValueError@missing_definitions.py:157] ValueError: Every non-aliased variable should be defined, but variable arg1#1 has no definition. #290

Open bugfinder-bot opened 1 year ago

bugfinder-bot commented 1 year ago

What happened?


  File "/opt/dewolf/decompiler/util/bugfinder/bugfinder.py", line 190, in iter_function_reports
    task_result = self.decompile(function, options)
  File "/opt/dewolf/decompile.py", line 51, in decompile
    pipeline.run(task)
  File "/opt/dewolf/decompiler/pipeline/pipeline.py", line 109, in run
    raise e
  File "/opt/dewolf/decompiler/pipeline/pipeline.py", line 102, in run
    instance.run(task)
  File "/opt/dewolf/decompiler/pipeline/preprocessing/missing_definitions.py", line 99, in run
    self.insert_missing_definitions()
  File "/opt/dewolf/decompiler/pipeline/preprocessing/missing_definitions.py", line 133, in insert_missing_definitions
    self._insert_definition_if_undefined(variable, previous_ssa_labels, undefined_variables)
  File "/opt/dewolf/decompiler/pipeline/preprocessing/missing_definitions.py", line 157, in _insert_definition_if_undefined
    raise ValueError(f"Every non-aliased variable should be defined, but variable {variable} has no definition.")

Error class ValueError@missing_definitions.py:157 contains 45 cases.

How to reproduce?

python decompile.py 6d6f438ff425f900a2582f1a7b4d661666d698ea1b2f8d40b393ab48b4c91b5d sub_2810 --debug

sample: 6d6f438ff425f900a2582f1a7b4d661666d698ea1b2f8d40b393ab48b4c91b5d case: https://bugfinder.seclab-bonn.de/case/2460/ dewolf commit: b8413c45 Binaryninja version: 3.4.4271

mm4rks commented 1 year ago

upstream: https://github.com/Vector35/binaryninja-api/issues/4504