-1

I'm developing a debugging automation system using https://github.com/MarioVilas/winappdbg.

I would like to retrieve process name from event object. Here is my code:

def EventHandler(event):
    print 'Inside event handler'
    # I want to print the  process name here, In this case which should be somefile.exe

debug = Debug( EventHandler, bKillOnExit = True )
proc = debug.execv(['c:\somefile.exe','arg'])
debug.loop()
  • What is the question? – julian Mar 25 '17 at 18:38
1

The tool author answered my question on github : Here is the solution

We can do event.get_process().get_filename(), or if we want to be more fancy:

process = event.get_process()
name = process.get_filename()
print "Process: %s" % name

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.