Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


GameGuard Hooking QUestion
Goto page Previous  1, 2
 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
Overload
Master Cheater
Reputation: 0

Joined: 08 Feb 2008
Posts: 293

PostPosted: Sat Aug 09, 2008 8:21 pm    Post subject: Reply with quote

fullyawesome wrote:
where do you learn all of this stuff? like about hooks and stuff?


...

_________________
Blog

Quote:
Rhys says:
you can be my maid
Rhys says:
ill buy you a french maid outfit
Tyler says:
Sounds good
Rhys says:
ill hold you to that
Back to top
View user's profile Send private message MSN Messenger
FullyAwesome
I post too much
Reputation: 0

Joined: 05 Apr 2007
Posts: 4438
Location: Land Down Under

PostPosted: Sat Aug 09, 2008 8:23 pm    Post subject: Reply with quote

Overload wrote:
fullyawesome wrote:
where do you learn all of this stuff? like about hooks and stuff?


...


yeah i know that, but i mean like by doing what? learning certain languages and doing what?

_________________
Back to top
View user's profile Send private message MSN Messenger
Overload
Master Cheater
Reputation: 0

Joined: 08 Feb 2008
Posts: 293

PostPosted: Sat Aug 09, 2008 8:38 pm    Post subject: Reply with quote

fullyawesome wrote:
Overload wrote:
fullyawesome wrote:
where do you learn all of this stuff? like about hooks and stuff?


...


yeah i know that, but i mean like by doing what? learning certain languages and doing what?


and looking at the interwebz? What do you think.

_________________
Blog

Quote:
Rhys says:
you can be my maid
Rhys says:
ill buy you a french maid outfit
Tyler says:
Sounds good
Rhys says:
ill hold you to that
Back to top
View user's profile Send private message MSN Messenger
&Vage
Grandmaster Cheater Supreme
Reputation: 0

Joined: 25 Jul 2008
Posts: 1053

PostPosted: Sun Aug 10, 2008 10:27 am    Post subject: Reply with quote

rapion124 wrote:
lurc wrote:
dnsi0 wrote:
Hows this get an autoinjector and inject npggNT.des into GG when it Loads @.@


Won't really matter, GameGuard dispatch's a lot of the important user-mode functions to the kernel, instead of using the user-mode function directly.


Correct, which is how one version of GGCRC works. Hook NtDeviceIoControlFile, make GG call NtDeviceIoControlFile and not directly using sysenter, and modify the parameters of GG's IOCTL to read memory. Although x0r only used it for GGCRC, it had a lot more potential such as crippling GG's driver, if only people decided to take a look at the source and not spend the few days it was released hacking MS. You can even stop GG's driver from loading and all you need to do is bypass the usermode hooks via a trampoline.


MapleStory and GameGuard's drivers love to make bitwise conversation Wink
Back to top
View user's profile Send private message
dnsi0
I post too much
Reputation: 0

Joined: 04 Jan 2007
Posts: 2674

PostPosted: Sun Aug 10, 2008 12:11 pm    Post subject: Reply with quote

So is it possible to rewrite the functions such as rpm with asm?

So copy the asm from rpm and construct your own function with it. Will that hop the hook or will the hook still own it?
Back to top
View user's profile Send private message
Slugsnack
Grandmaster Cheater Supreme
Reputation: 71

Joined: 24 Jan 2007
Posts: 1857

PostPosted: Sun Aug 10, 2008 12:22 pm    Post subject: Reply with quote

You can bypass a usermode hook that way but since your function will still eventually have to call the kernelmode version, that will still get hooked if it is a function hooked in kernelmode and other bits and pieces such as KiAttachProcess, etc. But if it just bypasses the usermode hook, a trampoline would just be much easier. Also bear in mind that your program would not be very "compatible" in that the code for APIs differ across different systems.

Although if you really want to go and totally recode an API including every kernel function it uses, then sure that would probably work in terms of bypassing GG's hooks.
Back to top
View user's profile Send private message
dnsi0
I post too much
Reputation: 0

Joined: 04 Jan 2007
Posts: 2674

PostPosted: Sun Aug 10, 2008 1:02 pm    Post subject: Reply with quote

Slugsnack wrote:
You can bypass a usermode hook that way but since your function will still eventually have to call the kernelmode version, that will still get hooked if it is a function hooked in kernelmode and other bits and pieces such as KiAttachProcess, etc. But if it just bypasses the usermode hook, a trampoline would just be much easier. Also bear in mind that your program would not be very "compatible" in that the code for APIs differ across different systems.

Although if you really want to go and totally recode an API including every kernel function it uses, then sure that would probably work in terms of bypassing GG's hooks.


Before I make any dumb sugestions can you tell me exacly what the kernel version of the hook works?
Back to top
View user's profile Send private message
lurc
Grandmaster Cheater Supreme
Reputation: 2

Joined: 13 Nov 2006
Posts: 1900

PostPosted: Sun Aug 10, 2008 2:34 pm    Post subject: Reply with quote

Well, ReadProcessMemory will still have to call NtReadVirtualMemory from the ntdll.dll, which will then do a sysenter and call NtReadVirtualMemory from ntoskrnl.exe. The SSDT of NtReadVirtualMemory is hooked via SSDT pointer modification.

Easy way around this, make a driver, store the original address before GameGuard installs its driver, call it from there.

But then there's another problem. KeAttachProcess via ntoskrnl.exe has a 5 byte hook at the beginning of the function. Not only that, functions it calls are also hooked (via 5 byte hook).

Fix for KeAttachProcess: Trampoline over the first 5 bytes.
Fix for inline calls: Hook the bytes before the hooked call, emulate the bytes instruction, then trampoline the first 5 bytes of the called address. (don't forget to emulate those bytes to). Then return after the inline call.

^ Thinking out loud, dunno if it really works, just seems logical.

Also another solution is to just load an entire new ntoskrnl.exe

_________________
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming All times are GMT - 6 Hours
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites