954,529 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Please C++ TO Delphi

Please C++ TO Delphi

IMAGE_NT_HEADERS* inh;
IMAGE_SECTION_HEADER* ish;

DWORD newRVA = (ish + inh->FileHeader.NumberOfSections - 1)->VirtualAddress + ((ish + inh->FileHeader.NumberOfSections - 1)->Misc.VirtualSize + (inh->OptionalHeader.SectionAlignment - (((ish + inh->FileHeader.NumberOfSections - 1)->Misc.VirtualSize % inh->OptionalHeader.SectionAlignment) ? ((ish + inh->FileHeader.NumberOfSections - 1)->Misc.VirtualSize % inh->OptionalHeader.SectionAlignment) : inh->OptionalHeader.SectionAlignment)));


newSecSize = (newSecSize + (inh->OptionalHeader.FileAlignment - ((newSecSize % inh->OptionalHeader.FileAlignment) ? (newSecSize % inh->OptionalHeader.FileAlignment) : inh->OptionalHeader.FileAlignment)));


ish->Misc.VirtualSize = (newSecSize + (inh->OptionalHeader.SectionAlignment - ((newSecSize % inh->OptionalHeader.SectionAlignment) ? (newSecSize % inh->OptionalHeader.SectionAlignment) : inh->OptionalHeader.SectionAlignment)));

DWORD* hVMImg;

DWORD _ssss = (*(DWORD*)(hVMImg + 7))*4 + (*(DWORD*)(hVMImg + 8))*8 + 4;


BYTE* outCodeBuf;
int outPos = 0;
BYTE* instr;

*(DWORD*)(outCodeBuf + outPos + 4) = (int)*((char*)instr + 3);
*(DWORD*)(outCodeBuf + outPos + 4) = *(DWORD*)(instr + 2);

BYTE* outCodeBuf;
int outPos = 0;
BYTE* codeBase;
int curPos = 0;
struct 
{
DWORD disasm_len;
} dis;

memmove(outCodeBuf + outPos + 1, codeBase + curPos, dis.disasm_len);
Leila1
Newbie Poster
5 posts since May 2009
Reputation Points: -11
Solved Threads: 0
 

See http://www.daniweb.com/forums/faq.php?faq=daniweb_policies for the forum rules before posting.

Do not post homework problems expecting a quick answer without showing any effort yourself. This especially pertains to the software development forums.

Why not see how much you can do by yourself. You'll learn more that way, and you may (god forbid) have a little fun :p

TeejMonster
Newbie Poster
22 posts since Jul 2009
Reputation Points: 9
Solved Threads: 2
 

They're just a helpless skiddie wannabe, trying to do something or other with someone else's malware kit.

I've seen it, it's rubbish.
http://www.daniweb.com/forums/thread194496.html
http://www.daniweb.com/forums/thread195594.html

Salem
Posting Sage
Team Colleague
11,531 posts since Dec 2005
Reputation Points: 5,862
Solved Threads: 953
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You