SoftSec-KAIST / TikNib

Binary Code Similarity Analysis (BCSA) Tool
MIT License
114 stars 22 forks source link

is it specific to elf files or can run with exe too? #10

Open nanda-rani opened 1 year ago

0xdkay commented 1 year ago

Current loader script (IDA wrapper) takes elf files as input tiknib/idascript.py. By slightly modifying this part, you can easily apply it for EXE files, too. The feature extraction part does not depend on the file format (ELF, EXE, ...).

BTW, you may need to remove EXE-specific functions that are not in your target package's source code. To check how we addressed such functions for ELF files, you may want to read Sec 3.2 in our paper.

nanda-rani commented 1 year ago

Thanks for your response. I'm new to binary analysis and have no idea of changes you're talking about. Can you help me with change required in tiknib/idascript.py. to make it work for EXE?

0xdkay commented 1 year ago

You can just make a file that contains a list of paths for EXE files. Then, give it as input. (see here and check example/input_list_find.txt.

If you want to use your own dataset (for EXE) and build the ground truth, You need to implement a custom code that extracts source file name and line number as we used for the step 3.

I am not sure about your testing environment and what you want to compare. It would be helpful if you provide detailed information.