DriverBuddyReloaded icon indicating copy to clipboard operation
DriverBuddyReloaded copied to clipboard

[BUG] module 'idaapi' has no attribute 'compiled_binpat_vec_t'

Open neobenedict opened this issue 3 years ago • 14 comments

Traceback (most recent call last):
  File "C:/Program Files/IDA 7.0/plugins/DriverBuddyReloaded.py", line 465, in run
    driver_type = utils.get_driver_id(driver_entry_addr, log_file)
  File "C:/Program Files/IDA 7.0/plugins\DriverBuddyReloaded\utils.py", line 209, in get_driver_id
    populate_wdf()
  File "C:/Program Files/IDA 7.0/plugins\DriverBuddyReloaded\wdf.py", line 102, in populate_wdf
    binpat = idaapi.compiled_binpat_vec_t()
AttributeError: module 'idaapi' has no attribute 'compiled_binpat_vec_t'

Version 7.5.201028 Windows x64 (64-bit address size)

7.6 minimum required?

neobenedict avatar Sep 04 '22 21:09 neobenedict

It was tested starting from IDA 7.6 but shouldn't be mandatory. Which version of python you're on?

VoidSec avatar Sep 06 '22 07:09 VoidSec

3.8.3

I'll try a later version of IDA in a few days.

neobenedict avatar Sep 06 '22 19:09 neobenedict

Same issue in IDA 7.5 and Python 3.9.4

zeze-zeze avatar Sep 24 '22 07:09 zeze-zeze

would you mind sharing the driver causing the error?

VoidSec avatar Sep 29 '22 07:09 VoidSec

Sure, it is not rare to find such driver. NVSWCFilter64.zip

zeze-zeze avatar Sep 29 '22 16:09 zeze-zeze

Tested on IDA 7.6 on Python 3.10.4, fixed in https://github.com/VoidSec/DriverBuddyReloaded/releases/tag/1.6

VoidSec avatar Oct 05 '22 16:10 VoidSec

Sorry to remention, but Im facing this on latest release. However, I'm on IDA v7.2. Any resolution for this?

rjt-gupta avatar May 23 '23 00:05 rjt-gupta

@rjt-gupta would you mind sharing the driver causing the error? You can send me an email at voidsec[at]voidsec.com if you'd like to keep it private.

VoidSec avatar May 23 '23 07:05 VoidSec

compiled_binpat_vec_t struct/class still did not existed in IDA SDK <= 7.5 image

HongThatCong avatar May 23 '23 10:05 HongThatCong

@HongThatCong thank you very much for pointing that out! I'll update the readme in order to reflect that requirement

VoidSec avatar May 23 '23 12:05 VoidSec

@HongThatCong @VoidSec Thanks for the clarification. Unfortunately, I can't share the driver since its proprietary. But, please let me know if there is a workaround for this issue for IDA < v7.5

rjt-gupta avatar May 24 '23 06:05 rjt-gupta

Yes, @VoidSec can rewrite the binary search function with code in picture above and this picture: If IDA <= 7.5 uses idaapi.find_binary function else uses idaapi_binsearch function. image Best regards, TQN

HongThatCong avatar May 24 '23 06:05 HongThatCong

@VoidSec Do you plan to fix this anytime soon?

rjt-gupta avatar May 31 '23 22:05 rjt-gupta

I'll probably take some time next week to patch some of these bugs.

VoidSec avatar Jun 02 '23 07:06 VoidSec