import idc print "MD5: {} Binary: {}".format(idc.GetInputMD5(), idc.GetInputFile()) !echo %PYTHONHOME% !where gcc !gcc -v !type %PYTHONHOME%\Lib\distutils\distutils.cfg %load_ext cythonmagic %%cython -+ -f -IC:/dev/IDA/idasdks/idasdk61/include -c "-D__NT__ -D__IDP__ -DWIN32" --link-args "C:/dev/IDA/idasdks/idasdk61/lib/x86_win_gcc_32/ida.a" cdef extern from "pro.h": pass cdef extern from "kernwin.hpp": int msg(const char* msg, ...) msg("Hello from Cython!\n") %%cython? %%cython -+ -f -lm -IC:/dev/IDA/idasdks/idasdk61/include -c "-D__NT__ -D__IDP__ -DWIN32" --link-args "C:/dev/IDA/idasdks/idasdk61/lib/x86_win_gcc_32/ida.a" ctypedef unsigned int ea_t ctypedef int bool cdef extern from "pro.h": cdef cppclass _qstring[T]: T *c_str() ctypedef _qstring[uchar] qtype cdef extern from "nalt.hpp": bool get_tinfo(ea_t ea, qtype *type, qtype *fields) cpdef pget_tinfo(ea_t ea): cdef qtype typ cdef qtype fields get_tinfo(ea, &typ, &fields) return typ.c_str(), fields.c_str() hex(idc.LocByName("_WinMain@16")) pget_tinfo(idc.LocByName("_WinMain@16"))