Exetools  

Go Back   Exetools > General > General Discussion

Notices

Reply
 
Thread Tools Display Modes
  #1  
Old 09-10-2004, 09:15
Crudd[RET] Crudd[RET] is offline
Friend
 
Join Date: Aug 2004
Posts: 28
Rept. Given: 0
Rept. Rcvd 0 Times in 0 Posts
Thanks Given: 0
Thanks Rcvd at 0 Times in 0 Posts
Crudd[RET] Reputation: 0
Heres an asm example of retrieving imagebase without using any apis (in case you dont wanna worry about importing new functions):
hxxp://spiff.tripnet.se/~iczelion/files/kernel.zip
The GetKernalBase proc is the one you want, and it shows the implementation at main. If you need some help with the example, let me know. Its pretty simple though.
Crudd [RET]
Reply With Quote
  #2  
Old 09-10-2004, 11:47
xastey
 
Posts: n/a
i found that abel loader generator v2.30 and DAZAPATCHER work great when you need to patch a protected .dll file. Used both of them with arma apps and hasn't failed me now
Reply With Quote
  #3  
Old 09-10-2004, 15:06
xobor xobor is offline
Friend
 
Join Date: May 2002
Location: Slovakia
Posts: 117
Rept. Given: 6
Rept. Rcvd 4 Times in 4 Posts
Thanks Given: 2
Thanks Rcvd at 23 Times in 15 Posts
xobor Reputation: 5
you can do something like

Code:
	if(!CreateProcess(name,...))
	{
                 printf("err createprocess");
	    return 0;
	}

DebugLoop:

	WaitForDebugEvent(&DebugEvent, INFINITE);
	if(DebugEvent.dwDebugEventCode==LOAD_DLL_DEBUG_EVENT)
	{
	   //DebugEvent.u.LoadDll.lpBaseOfDll - is base of dll
             }
.
.
.
maybe it helps
Reply With Quote
  #4  
Old 09-10-2004, 21:15
Crk
 
Posts: n/a
i found that abel loader generator v2.30 and DAZAPATCHER work great when you need to patch a protected .dll file.

how? if loaders run an exe target .. how you patch those dll in mem. with a loader...
Reply With Quote
  #5  
Old 09-10-2004, 22:16
xastey
 
Posts: n/a
i just set it to load the exe and then set the patch data to the offest of the .dll
Reply With Quote
  #6  
Old 09-11-2004, 01:17
Line79
 
Posts: n/a
Hello,

I don't understand the problem here.

The dll will be loaded in the SAME context than the EXE file.
Therefore, you could patch the dll if you could control the EXE file code.

But what you can just do, is CreateProcess the EXE file, and then, instead of providing a VA inside the Target EXE (which you don't want to do, since you want to patch the dll), you just provide a VA inside the DLL to WriteProcessMemory, and since , the dll is in the same Address space (context) than the EXE file, you writeprocessmemory will work, and thus, you will be patching your protected dll without problems.

Cheers.
Reply With Quote
  #7  
Old 09-12-2004, 03:09
Peace99
 
Posts: n/a
I just use this trick

just use Process Patcher v3.60
Search memory address you want to patch and create Process Patcher v3.60
it's will patch memory on the fly.

see my attachment in powerbasic source (to enable official counter-strike 1.6 bots.)

I use this trick, convert Process Patcher v3.60 to hex and store inside the source code. see the source for detail.

this how i create loader/launcher.
Attached Files
File Type: rar cstrike.rar (64.1 KB, 83 views)
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
Loader and Patch Dll file in C# mcr4ck Source Code 0 06-19-2022 23:59
Creating a Loader for DotNet Apps? bball0002 General Discussion 2 09-24-2009 22:06


All times are GMT +8. The time now is 16:53.


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