objection icon indicating copy to clipboard operation
objection copied to clipboard

[bug] Device not detected

Open lecatos opened this issue 1 year ago • 3 comments

Describe the bug Objection cannot find devices even adb is there. I am trying to run objection on NOX player.

To Reproduce objection -n appname start

Expected behavior No error

Evidence / Logs / Screenshots File "C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages\objection\utils\agent.py", line 186, in set_device raise Exception('Unable to find a device') Exception: Unable to find a device

FIX the fix is not eligant but it works. maybe the owner can find a more elegant solution.

in agent.py

import time

//line 170-180 elif self.config.device_type is not None: tmp = frida.enumerate_devices() // to initiate frida (this one doesnt include the usb device) time.sleep(1) // let frida run for a bit so that it include the usb device for dev in frida.enumerate_devices(): // use the frida again so that this time it include the usb device if dev.type == self.config.device_type: self.device = dev //sucessfully set the device

lecatos avatar Nov 28 '25 08:11 lecatos

the bug itself is because of frida

lecatos avatar Nov 28 '25 08:11 lecatos

Which version of objection are you using?

IPMegladon avatar Nov 28 '25 08:11 IPMegladon

v1.12.2

same issue here -> https://github.com/frida/frida/issues/1111

lecatos avatar Nov 28 '25 10:11 lecatos