cea-sec / miasm

Reverse engineering framework in Python
https://miasm.re/
GNU General Public License v2.0
3.48k stars 474 forks source link

Test cases status - Linux Ubuntu 22.04 #1498

Open greenozon opened 2 months ago

greenozon commented 2 months ago

I tried to run all the tests, after installing optional prereqs

cat /etc/issue
Ubuntu 22.04.4 LTS \n \l

pip3 install -r ./optional_requirements.txt

python3 -V
Python 3.10.12

pip3 freeze | grep miasm
miasm==0.1.5

and it turned out there are dozens of failed TCs... 72 TC with ERROR status

cat miasm_test_all.txt | grep "ERROR "
ERROR aarch64/arch.py
ERROR arm/sem.py llvm
ERROR arm/sem.py python
ERROR depgraph.py ../samples/simple_test.bin -m x86_32 0x0 0x8b EAX -i --rename-args
ERROR unpack_generic.py ../samples/box_upx.exe --jitter python -o
ERROR arm/arch.py
ERROR arm/sem.py gcc
ERROR unpack_generic.py ../samples/box_upx.exe --jitter gcc -o
ERROR unpack_generic.py ../samples/box_upx.exe --jitter llvm -o
ERROR depgraph.py ../samples/simple_test.bin -m x86_32 0x0 0x8b EAX
ERROR dg_check.py dg_test_01_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_01.bin 0x401000 0x401011 EAX
ERROR dg_check.py dg_test_00_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_00.bin 0x401000 0x40100d EAX
ERROR dg_check.py dg_test_01_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_01.bin 0x401000 0x401011 EAX -i
ERROR dg_check.py dg_test_00_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_00.bin 0x401000 0x40100d EAX -i
ERROR dg_check.py dg_test_02_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_02.bin 0x401000 0x401018 EAX
ERROR dg_check.py dg_test_02_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_02.bin 0x401000 0x401018 EAX -i
ERROR dg_check.py dg_test_03_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_03.bin 0x401000 0x401011 EAX
ERROR dg_check.py dg_test_04_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_04.bin 0x401000 0x401011 EAX -i
ERROR dg_check.py dg_test_04_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_04.bin 0x401000 0x401011 EAX
ERROR dg_check.py dg_test_03_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_03.bin 0x401000 0x401011 EAX -i
ERROR dg_check.py dg_test_05_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_05.bin 0x401000 0x401016 EAX -i
ERROR dg_check.py dg_test_05_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_05.bin 0x401000 0x401016 EAX
ERROR dg_check.py dg_test_06_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_06.bin 0x401000 0x401017 EAX -i
ERROR dg_check.py dg_test_06_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_06.bin 0x401000 0x401017 EAX
ERROR dg_check.py dg_test_07_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_07.bin 0x401000 0x401012 EAX ECX
ERROR dg_check.py dg_test_07_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_07.bin 0x401000 0x401012 EAX ECX -i
ERROR dg_check.py dg_test_09_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_09.bin 0x401000 0x40101f EAX EBX -i
ERROR dg_check.py dg_test_08_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_08.bin 0x401000 0x401012 ECX
ERROR dg_check.py dg_test_08_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_08.bin 0x401000 0x401012 ECX -i
ERROR dg_check.py dg_test_09_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_09.bin 0x401000 0x40101f EAX EBX
ERROR dg_check.py dg_test_11_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_11.bin 0x401000 0x401007 EBX
ERROR dg_check.py dg_test_11_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_11.bin 0x401000 0x401007 EBX -i
ERROR dg_check.py dg_test_10_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_10.bin 0x401000 0x401025 EAX EBX -i
ERROR dg_check.py dg_test_10_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_10.bin 0x401000 0x401025 EAX EBX
ERROR depgraph.py ../samples/x86_32_if_reg.bin -m x86_32 0x0 0x19 EAX
ERROR depgraph.py ../samples/x86_32_if_reg.bin -m x86_32 0x0 0x19 EAX -i --rename-args
ERROR aarch64/arch.py
ERROR arm/sem.py llvm
ERROR arm/sem.py python
ERROR depgraph.py ../samples/simple_test.bin -m x86_32 0x0 0x8b EAX -i --rename-args
ERROR unpack_generic.py ../samples/box_upx.exe --jitter python -o
ERROR arm/arch.py
ERROR arm/sem.py gcc
ERROR unpack_generic.py ../samples/box_upx.exe --jitter gcc -o
ERROR unpack_generic.py ../samples/box_upx.exe --jitter llvm -o
ERROR depgraph.py ../samples/simple_test.bin -m x86_32 0x0 0x8b EAX
ERROR dg_check.py dg_test_01_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_01.bin 0x401000 0x401011 EAX
ERROR dg_check.py dg_test_00_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_00.bin 0x401000 0x40100d EAX
ERROR dg_check.py dg_test_01_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_01.bin 0x401000 0x401011 EAX -i
ERROR dg_check.py dg_test_00_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_00.bin 0x401000 0x40100d EAX -i
ERROR dg_check.py dg_test_02_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_02.bin 0x401000 0x401018 EAX
ERROR dg_check.py dg_test_02_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_02.bin 0x401000 0x401018 EAX -i
ERROR dg_check.py dg_test_03_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_03.bin 0x401000 0x401011 EAX
ERROR dg_check.py dg_test_04_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_04.bin 0x401000 0x401011 EAX -i
ERROR dg_check.py dg_test_04_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_04.bin 0x401000 0x401011 EAX
ERROR dg_check.py dg_test_03_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_03.bin 0x401000 0x401011 EAX -i
ERROR dg_check.py dg_test_05_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_05.bin 0x401000 0x401016 EAX -i
ERROR dg_check.py dg_test_05_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_05.bin 0x401000 0x401016 EAX
ERROR dg_check.py dg_test_06_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_06.bin 0x401000 0x401017 EAX -i
ERROR dg_check.py dg_test_06_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_06.bin 0x401000 0x401017 EAX
ERROR dg_check.py dg_test_07_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_07.bin 0x401000 0x401012 EAX ECX
ERROR dg_check.py dg_test_07_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_07.bin 0x401000 0x401012 EAX ECX -i
ERROR dg_check.py dg_test_09_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_09.bin 0x401000 0x40101f EAX EBX -i
ERROR dg_check.py dg_test_08_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_08.bin 0x401000 0x401012 ECX
ERROR dg_check.py dg_test_08_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_08.bin 0x401000 0x401012 ECX -i
ERROR dg_check.py dg_test_09_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_09.bin 0x401000 0x40101f EAX EBX
ERROR dg_check.py dg_test_11_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_11.bin 0x401000 0x401007 EBX
ERROR dg_check.py dg_test_11_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_11.bin 0x401000 0x401007 EBX -i
ERROR dg_check.py dg_test_10_implicit_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_10.bin 0x401000 0x401025 EAX EBX -i
ERROR dg_check.py dg_test_10_expected.json ../../example/symbol_exec/depgraph.py -m x86_32 --json ../samples/x86_32/dg_test_10.bin 0x401000 0x401025 EAX EBX
ERROR depgraph.py ../samples/x86_32_if_reg.bin -m x86_32 0x0 0x19 EAX
ERROR depgraph.py ../samples/x86_32_if_reg.bin -m x86_32 0x0 0x19 EAX -i --rename-args

my quesiton is: is that expected and is there any recurrent TC run to compare with?

the full logs of the TC run attached

miasm_test_all.txt

W0ni commented 2 months ago

This is odd, the test cases are ran by the CI, and succedded. Moreover, they are ran on Ubuntu.

You can see the results of the tests here for example : https://github.com/cea-sec/miasm/actions/runs/10330657267/job/28599954642