professor-hippo / idapython

Automatically exported from code.google.com/p/idapython
Other
0 stars 0 forks source link

autoWait() not defined for idaw.exe #67

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
IDA 6.1.1100421
IDAPython v1.5.0 final (serial 0)

Enter idaw (text-based version). File > Enter Python command. Enter autoWait() 
and press OK.  Get 

   NameError: name 'autoWait' is not defined

I encountered this because I'm trying to run a python script that calls 
autoWait() on startup of an IDA session. This is started from a batch file with 
the following command line:

   idaw -A -c -L"logfile.txt" -OIDAPython:script.py main.exe

Looking at logfile.txt, I see the same error:

   name 'autoWait' is not defined
   Traceback (most recent call last):
     File "c:\Program Files (x86)\IDA\python\idaapi.py", line 373, in IDAPython_ExecScript
       execfile(script, g)
     File "script.py", line 6, in <module>
       autoWait()
   NameError: name 'autoWait' is not defined

If I replace 'idaw' with 'idag', the problem is not encountered, however, I 
didn't want to spawn a GUI in this batch process.

Original issue reported on code.google.com by jonathon...@gmail.com on 7 Jun 2011 at 8:27

Attachments:

GoogleCodeExporter commented 9 years ago
This also applies to "idal" on linux.

Original comment by jonathon...@gmail.com on 7 Jun 2011 at 9:31

GoogleCodeExporter commented 9 years ago
My mistake - it does exist, but you need to call it using the module name:

idaapi.autoWait()

Sorry for the confusion. However, this is different from idaq/idag which 
apparently import * from idaapi.  And also doesn't match the example at 
http://www.openrce.org/articles/full_view/11

Original comment by jonathon...@gmail.com on 8 Jun 2011 at 3:45

GoogleCodeExporter commented 9 years ago

Original comment by elias.ba...@gmail.com on 4 Jul 2011 at 2:36