vusec / vuzzer64

This implements a 64-bit version of vusec/vuzzer fuzzing tool.
Apache License 2.0
175 stars 51 forks source link

Fix pin deprecation warnings #22

Closed PBearson closed 2 years ago

PBearson commented 3 years ago

It seems like pin has deprecated some of the functions used by VUzzer. It seems like the old versions of pin (e..g, 3.7), which might have used these functions, are not easily accessible. This patch changes only 2 API calls in bbcounts2.cpp.

PBearson commented 3 years ago

Updated readme to reflect the change in new pin version. Also made a slight change to gitignore.

PBearson commented 3 years ago

libdft64 has some deprecated calls to pin as well. I will patch them soon.

tosanjay commented 3 years ago

libdft64 has some deprecated calls to pin as well. I will patch them soon.

Yes, that will be needed if we really want to recommend latest version on Pin. Thank you. So, I think it is better to wait for your next fix before we merge your PR?

PBearson commented 3 years ago

libdft64 has some deprecated calls to pin as well. I will patch them soon.

Yes, that will be needed if we really want to recommend latest version on Pin. Thank you. So, I think it is better to wait for your next fix before we merge your PR?

I updated libdft_core.cpp to use the new function. I compared cmp.out and lea.out between the patched version and unpatched version of libdft_dta.so, and there was no change in the output files. This makes me think that the fix should have no effect on VUzzer's behavior (aside from remove deprecation warnings).

tosanjay commented 2 years ago

Hi @PBearson thank you. I was relocating to another country, so lost track of this thread and PR. Can you please let me know which application you used to run different versions of VUzzers and what were the size of cmp.out and lea.out files? This will give us more confidence about the changes and their effects. I will then merge the PR. once again, thanks for contributing to this repo.

PBearson commented 2 years ago

Hi @PBearson thank you. I was relocating to another country, so lost track of this thread and PR. Can you please let me know which application you used to run different versions of VUzzers and what were the size of cmp.out and lea.out files? This will give us more confidence about the changes and their effects. I will then merge the PR. once again, thanks for contributing to this repo.

I ran libdft-dta on readelf. For input files, I gave it the binaries ls, ln, mdsum, and tar. To check for similarity between vusec/vuzzer64 and pbearson/vuzzer64, I just ran the following script in both repos and compared the shasum of the output files:

#!/bin/bash

function run_libdft_dta () 
{
    $PIN_ROOT/pin -t tools/libdft-dta.so -filename $1 -x 0 -- ./readelf -a $1
    mv cmp.out "cmp.pbearson.$1.out"
    mv lea.out "lea.pbearson.$1.out"
}

run_libdft_dta "ls"
run_libdft_dta "ln"
run_libdft_dta "md5sum"
run_libdft_dta "tar"

You can see the attached zip file, which contains the tested application, input files, and output files.

vuzzer-files.zip