Flag: Tornado! Hurricane!

 Forums >>  Debuggers  >>  PyDBG, threads that don't like to be single stepped?

Topic created on: February 22, 2012 21:39 CST by nomnom .

Hey everyone, I've got a question about using PyDBG. I'm trying to debug the latest VLC, and everything works just fine if I do a simple thing like :

dbg = pydbg()
dbg.load("vlc.exe")
dbg.run()

Now, the problem is if I set new threads to single_step(True), the program will basically hang at a certain point. And it's not at the first thread or anything, it's later in the program, roughly 5 threads in. The only change I make is :

def handle_new_thread(dbg):
    dbg.single_step(True)
    return DBG_CONTINUE

def handle_single_step(dbg):
    dbg.single_step(True)
    return DBG_CONTINUE

...

dbg.set_callback(EXCEPTION_SINGLE_STEP,     handle_single_step)
dbg.set_callback(CREATE_THREAD_DEBUG_EVENT, handle_new_thread)

And this will work on some programs, but on some (like VLC 2.0) in this instance, it will just hang at some point. The question is, any ideas why setting a thread to single step would cause an issue?

Thanks for the help, it's much appreciated.

No posts found under this topic.
Note: Registration is required to post to the forums.

There are 29,881 total registered users.


Recently Created Topics
PaiMei stalker modul...
May/19
Attach to program us...
May/13
IDA PRO how to make ...
May/12
FACT: OpenRCE is dead.
May/08
Int 3 anti debug?
May/05
help needed - Beginn...
May/03
Attaching IDA Pro to...
Apr/27
File type
Apr/21
Debugging iphone app...
Apr/15
Attaching
Apr/12


Recent Forum Posts
Ollydbg 2.0 - Plugin...
openrce...
IDA PRO how to make ...
codeinject
FACT: OpenRCE is dead.
codeinject
IDA Resource Viewer ...
r2x64
FACT: OpenRCE is dead.
djnemo
FACT: OpenRCE is dead.
codeinject
FACT: OpenRCE is dead.
pedram
help needed - Beginn...
araujo
Attaching IDA Pro to...
codeinject
Int 3 anti debug?
codeinject


Recent Blog Entries
sweetyss
May/18
Adam Wainwright continues t...

lowpriority
Apr/13
OllyMigrate Plugin for Olly...

everdox
Mar/08
2 anti-trace mechanisms spe...

everdox
Mar/07
Advanced debugging techniques

everdox
Mar/06
Branch tracing and LBR acce...

More ...


Recent Blog Comments
clarisonic on:
Apr/03
New version of Ollydbg!

clarisonic on:
Apr/03
New version of Ollydbg!

trackerx90 on:
Mar/04
SuppressDebugMsg As Anti-De...

coachfactory on:
Feb/25
Portable Executable Format ...

coachfactory on:
Feb/25
A new Anti-Olly trick.

More ...


Imagery
SoySauce Blueprint
Jun 6, 2008

[+] expand

View Gallery (11) / Submit