Exetools  

Go Back   Exetools > General > General Discussion

Notices

Reply
 
Thread Tools Display Modes
  #1  
Old 03-01-2015, 21:11
mcp mcp is offline
Friend
 
Join Date: Dec 2011
Posts: 73
Rept. Given: 4
Rept. Rcvd 12 Times in 11 Posts
Thanks Given: 7
Thanks Rcvd at 47 Times in 35 Posts
mcp Reputation: 12
Not sure I really understand your question.
It seems you're asking on how to reconstruct the original register based instructions? That is not possible, as that information is destroyed.

For example, given that stack based VM, you cannot distinguish

Code:
mov eax,ebx
mov ecx,eax
mov edx,ecx
from

Code:
mov ebx,eax
mov edx,ebx
mov ecx,edx
What you can do however, is what in compiler construction is called "register allocation". It basically means, that you start with arbitrarily many variables (in this case your stack variables from the stack machine) and find an allocation of assigning these variables to registers while at the same time trying to minimize the amount of register spills. Even a greedy algorithm should work sufficiently well in that case.
OTOT, for what reason do you actually want to dos this anyway? Re-assemble VM code?
Reply With Quote
The Following User Gave Reputation+1 to mcp For This Useful Post:
Conquest (03-01-2015)
  #2  
Old 03-01-2015, 21:44
Conquest Conquest is offline
Friend
 
Join Date: Jan 2013
Location: 0x484F4D45
Posts: 125
Rept. Given: 46
Rept. Rcvd 29 Times in 17 Posts
Thanks Given: 33
Thanks Rcvd at 60 Times in 29 Posts
Conquest Reputation: 29
Quote:
Originally Posted by mcp View Post
OTOT, for what reason do you actually want to dos this anyway? Re-assemble VM code?
Yes . Also you got my question correctly. weird enough in themida cisc vm they preserve the register information while vmp completely wipes it (unless they are using some hidden tricks like water marking the register handlers or assign the vm pcode with certain algo which encrypts the register information) , i cant find the register information at all.
Thanks for your info anyway. I will look forward to have advice from more people involved in this area.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Sentinel SHK Virtual Machine phroyt General Discussion 4 07-05-2022 23:51
You do not have a Codewizard for C++ 4.3 license for this machine matrowang General Discussion 0 05-10-2004 15:19
Softice rebooting my machine Mok General Discussion 4 09-07-2003 00:01


All times are GMT +8. The time now is 05:32.


Always Your Best Friend: Aaron, JMI, ahmadmansoor, ZeNiX, chessgod101
( Since 1998 )