mandiant / capa

The FLARE team's open-source tool to identify capabilities in executable files.
https://mandiant.github.io/capa/
Apache License 2.0
4.85k stars 557 forks source link

CI: use frozen features during linting to improve performance #423

Open williballenthin opened 3 years ago

mr-tz commented 3 years ago

to make this practical, we need an automatism to regenerate frozen feature files after a code update

mr-tz commented 3 years ago

saving the viv workspaces likely produces similar performance improvements, but has the same issue wrt updating those files

mr-tz commented 3 years ago

$ time ../venv3/Scripts/python scripts/lint.py --thorough rules/ -t "process" real 4m3.716s

with frozen features: $ time ../venv3/Scripts/python scripts/lint.py --frozen tests/data/frozen --thorough rules/ -t "process" real 2m20.567s

williballenthin commented 5 months ago

Rather than using frozen features, we might consider using BinExport2 files. I think the performance should be similar. The freeze format really isn't used for anything, so imho its maybe a candidate to be removed (discussion needed). Therefore, we shouldn't add a new use for it unless we really want it.

mr-tz commented 5 months ago

great point, BinExport sounds like a nice solution here