![]() |
|
|
|
#1
|
|||
|
|||
|
I think that for real hooking you will need to write ring0 driver. This ring3 hooking with dll injection is not enough releable technique.
|
|
#2
|
|||
|
|||
|
Phrack to the rescue perhaps?
hxxp://www.phrack.org/show.php?p=62&a=6
Dig through that, it will give you some rather interesting ideas at the very least. |
|
#3
|
|||
|
|||
|
Quote:
As for reliability, it's simply best to allocate a buffer of say, 20 bytes of nops, and a jmp , use a LDE, scan the first few instructions, until the length you have scanned exceeds 6 (push dword / retn, it must be direct, not relative, so it can be hooked again), copy those instructions into your empty buffer, patch the entrypoint, repair the empty jump in the buffer, and that shall act as a stub your hooking procedure calls to return to the original function. I, personally, think this is the most reliable way out there. as for dll-injection, open a process, retreive its threads, use OpenThread() to convert dwThreadID to hThread, SuspendThread(), GetThreadContext(), alter eip, SetThreadContext(), and inject a CreateThread() call, then resume the thread. OpenThread() is "officially" only avaliable on NT, but there are plenty of undocummented ways to achieve the same. ok just my 2 cents. |
|
#4
|
|||
|
|||
|
It looks like toas is running a pre-NT windows OS. I don't see why the described method would work on NT4.0+.
|
|
#5
|
||||
|
||||
|
Quote:
Quote from Validtec: "APIHookxp.dll: Win32 API Hook DLL for WINNT/2000/XP APIHook9x.dll: Win32 API Hook DLL for WIN9X/WINME" It's valid for different OS. You only need to distribute the right dlll or both.
|
|
#6
|
|||
|
|||
|
For hide file on HardDisc, maybe you should learn some stealth techniq from phrack.
For hide pe file on running, you can coding to change own PEB; hook some api, and even inject own into other process |
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Can you hide/remove packer info from file? | spokey | General Discussion | 10 | 01-08-2005 00:56 |
| Hide SoftIce under XP | Lindwurm | General Discussion | 4 | 04-26-2003 03:10 |