NeonFlash
March 26th, 2012, 12:11
I am analyzing one malware which injects code into explorer.exe using WriteProcessMemory().
Once it injects the malicious code, it then runs this code using CreateRemoteThread().
Now, moment I step over the call to CreateRemoteThread instruction, the malware runs inside the debugger.
I want step over the code injected into explorer.exe and analyze it.
In order to do so, I attached another Olly Debugger to explorer.exe. Now it brings me to ntdll.DbgBreakPoint
it freezes the VM, probably because explorer.exe is paused inside the debugger.
Next, I modified the values passed by malware to OpenProcess so that now it injects the code in another process like calc.exe instead of explorer.exe
Once again, after reaching the Call to CreateRemoteThread() inside the virus code, I attached another Olly Debugger to calc.exe process.
I used the base address of code which was passed as a parameter to CreateRemoteThread() and checked it in calc.exe inside Olly Debugger. I can see the code injected.
Now, I want to be able to trigger this code and execute it step by step.
If I step over the CreateRemoteThread() instruction in virus, it will crash because calc.exe is already paused inside debugger. So, Remote Thread will not execute.
Is there a way to analyze the Remote Thread?
Once it injects the malicious code, it then runs this code using CreateRemoteThread().
Now, moment I step over the call to CreateRemoteThread instruction, the malware runs inside the debugger.
I want step over the code injected into explorer.exe and analyze it.
In order to do so, I attached another Olly Debugger to explorer.exe. Now it brings me to ntdll.DbgBreakPoint
it freezes the VM, probably because explorer.exe is paused inside the debugger.
Next, I modified the values passed by malware to OpenProcess so that now it injects the code in another process like calc.exe instead of explorer.exe
Once again, after reaching the Call to CreateRemoteThread() inside the virus code, I attached another Olly Debugger to calc.exe process.
I used the base address of code which was passed as a parameter to CreateRemoteThread() and checked it in calc.exe inside Olly Debugger. I can see the code injected.
Now, I want to be able to trigger this code and execute it step by step.
If I step over the CreateRemoteThread() instruction in virus, it will crash because calc.exe is already paused inside debugger. So, Remote Thread will not execute.
Is there a way to analyze the Remote Thread?