xoreaxeaxeax / sandsifter

The x86 processor fuzzer
BSD 3-Clause "New" or "Revised" License
4.9k stars 350 forks source link

Unable to run under Arch #1

Open ghost opened 7 years ago

ghost commented 7 years ago

Hi,

I'm trying to test sandsifter on Arch. After manually specifying python2, I get:

$> sudo ./sifter.py --unk --dis --len --sync --tick -- -P1 -t
Traceback (most recent call last):
  File "./sifter.py", line 842, in <module>
    main()
  File "./sifter.py", line 817, in main
    arch = re.search(r".*(..)-bit.*", injector_bitness).group(1)
AttributeError: 'NoneType' object has no attribute 'group'

Please let me know if you need any more info or testing.

esquire900 commented 7 years ago

Same error here, Ubuntu 17.04 (anaconda python installation)

sokoow commented 7 years ago

Same here, centos 7

sokoow commented 7 years ago

Ok I found out why, you need to download capstone from git, then compile it, and then run make inside sifter directory. This will compile the injector and then all works well.

ghost commented 7 years ago

@sokoow : I've installed capstone-git but I can't run make because I encounter #2 .

$> make
cc  -c injector.c -o injector.o -Wall
injector.c:321:93: warning: excess elements in array initializer
 00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00}, .len                                              =0},
                                                                     ^~~~
injector.c:321:93: note: (near initialization for ‘total_range.start.bytes’)
injector.c:322:91: warning: excess elements in array initializer
 ff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff}, .len                                              =0},
                                                                     ^~~~
injector.c:322:91: note: (near initialization for ‘total_range.end.bytes’)
cc  injector.o -O3 -Wall -l:libcapstone.a -o injector -pthread
/usr/bin/ld: cannot find -l:libcapstone.a
collect2: error: ld returned 1 exit status
make: *** [Makefile:35: injector] Error 1
sokoow commented 7 years ago

it compiled fine for me under centos7 :/

FauxFaux commented 7 years ago

On Ubuntu, the necessary libraries are packaged:

sudo apt install python-capstone libcapstone-dev
make
sudo ./sifter.py --unk --dis --len --sync --tick -- -P1 -t