View Single Post
  #1  
Old 09-08-2004, 23:53
<|nAbOo|>
 
Posts: n/a
Creating a Loader to modify a DLL file

Hi,

well i have a small question concerning Loaders.

Lets imagine i have a EXE file and a DLL file which check eachother for
CRC and different things and dont like modifying. The idea now is to create
a loader which patches the files in memory at runtime. For the EXE file i can use the following APIs to modify the code in memory:

invoke CreateProcessA,offset LoadszFileName,0,0,0,0,CREATE_SUSPENDED, \
0,0,offset LoadlpStartupInfo,offset LoadlpProcessInfo

invoke WriteProcessMemory,LoadlpProcessInfo.hProcess,LoadlpBaseAddress, \
offset LoadlpBuffer,LoadcbWrite,NULL

invoke ResumeThread,LoadlpProcessInfo.hThread

Now my question: How can i modify a DLL file in memory using such tactic.
Someone ever tried things like that before ?

Thanks in Advance
naboo
Reply With Quote