BayshoreNetworks / yextend

Yara integrated software to handle archive file data.
BSD 3-Clause "New" or "Revised" License
299 stars 59 forks source link

Yara 3 Compiler Errors #1

Closed ceelias closed 9 years ago

ceelias commented 9 years ago

make all-am make[1]: Entering directory /home/chris/Bayshore/yextend' gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT bayshore_yara_wrapper.o -MD -MP -MF .deps/bayshore_yara_wrapper.Tpo -c -o bayshore_yara_wrapper.o bayshore_yara_wrapper.c bayshore_yara_wrapper.c: In function ‘bayshore_yara_preprocess_rules’: bayshore_yara_wrapper.c:286:4: warning: passing argument 2 of ‘yr_compiler_set_callback’ from incompatible pointer type [enabled by default] In file included from /usr/local/include/yara.h:22:0, from bayshore_yara_wrapper.h:27, from bayshore_yara_wrapper.c:28: /usr/local/include/yara/compiler.h:138:13: note: expected ‘YR_COMPILER_CALLBACK_FUNC’ but argument is of type ‘void (*)(int, const char *, int, const char *)’ bayshore_yara_wrapper.c: In function ‘bayshore_yara_wrapper_api’: bayshore_yara_wrapper.c:480:4: warning: passing argument 2 of ‘yr_compiler_set_callback’ from incompatible pointer type [enabled by default] In file included from /usr/local/include/yara.h:22:0, from bayshore_yara_wrapper.h:27, from bayshore_yara_wrapper.c:28: /usr/local/include/yara/compiler.h:138:13: note: expected ‘YR_COMPILER_CALLBACK_FUNC’ but argument is of type ‘void (*)(int, const char *, int, const char *)’ mv -f .deps/bayshore_yara_wrapper.Tpo .deps/bayshore_yara_wrapper.Po g++ -g -O2 -o yextend filedissect.o wrapper.o bayshore_content_scan.o filedata.o main.o zl.o bayshore_yara_wrapper.o -lpcrecpp -lz -lyara -lcrypto -larchive make[1]: Leaving directory/home/chris/Bayshore/yextend'

garbagecat commented 9 years ago

hmm, is this a regression? Did you update to a newer version of the yara code?

On Wed, May 27, 2015 at 6:31 PM, ceelias notifications@github.com wrote:

make all-am make[1]: Entering directory /home/chris/Bayshore/yextend' gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT bayshore_yara_wrapper.o -MD -MP -MF .deps/bayshore_yara_wrapper.Tpo -c -o bayshore_yara_wrapper.o bayshore_yara_wrapper.c bayshore_yara_wrapper.c: In function ‘bayshore_yara_preprocess_rules’: bayshore_yara_wrapper.c:286:4: warning: passing argument 2 of ‘yr_compiler_set_callback’ from incompatible pointer type [enabled by default] In file included from /usr/local/include/yara.h:22:0, from bayshore_yara_wrapper.h:27, from bayshore_yara_wrapper.c:28: /usr/local/include/yara/compiler.h:138:13: note: expected ‘YR_COMPILER_CALLBACKFUNC’ but argument is of type ‘void ()(int, const char , int, const char )’ bayshore_yara_wrapper.c: In function ‘bayshore_yara_wrapper_api’: bayshore_yara_wrapper.c:480:4: warning: passing argument 2 of ‘yr_compiler_set_callback’ from incompatible pointer type [enabled by default] In file included from /usr/local/include/yara.h:22:0, from bayshore_yara_wrapper.h:27, from bayshore_yara_wrapper.c:28: /usr/local/include/yara/compiler.h:138:13: note: expected ‘YR_COMPILER_CALLBACKFUNC’ but argument is of type ‘void ()(int, const char , int, const char )’ mv -f .deps/bayshore_yara_wrapper.Tpo .deps/bayshore_yara_wrapper.Po g++ -g -O2 -o yextend filedissect.o wrapper.o bayshore_content_scan.o filedata.o main.o zl.o bayshore_yara_wrapper.o -lpcrecpp -lz -lyara -lcrypto -larchive make[1]: Leaving directory/home/chris/Bayshore/yextend'

— Reply to this email directly or view it on GitHub https://github.com/BayshoreNetworks/yextend/issues/1.

ceelias commented 9 years ago

Yes these are the errors that are given with the latest version of Yara. Dre asked me to post my results here.

dre commented 9 years ago

So it seems some functions we call on the yara side have changed (they now have an extra argument). Will fix, this means that yextend 1.2 will only work with yara 3.3 and above.

garbagecat commented 9 years ago

You probably ought to tell the Yara guy that it's not nice to break his users's code.

Another fucked up thing is that if you're using C instead of C++, there's no compiler-level breakage. Your code just won't work.

On Thu, May 28, 2015 at 1:43 PM, Dre notifications@github.com wrote:

So it seems some functions we call on the yara side have changed (they now have an extra argument). Will fix, this means that yextend 1.2 will only work with yara 3.3 and above.

— Reply to this email directly or view it on GitHub https://github.com/BayshoreNetworks/yextend/issues/1#issuecomment-106519244 .

dre commented 9 years ago

Chris, try again with version 1.2 of yextend.