From: Yue C. <yc...@gm...> - 2015-02-06 18:07:44
|
Dear all, I am working on a project that needs to disassemble FreeBSD kernel code in memory. I tried to use Capstone in my kernel module. However, when I link "libcapstone.a" with my kernel module object, there would be errors like no symbol "sprintf", "memset", "memcpy", etc. After implementing them on my own in another library, the kernel always crashes when executing "cs_open". I followed the instructions on http://www.capstone-engine.org/embed.html to replace the memory allocation functions and vsnprintf with FreeBSD kernel's, but the problems still exist. Anyone could give an idea or example about how to implement it in a better way (even a better Makefile to link them)? Many thanks and regards, Yue |