Dll dont work

Siedler

Active member
Joined
Oct 21, 2013
Messages
34
Reaction score
1
Today i begun with dll hacking and looked a few tutorials,
now i tried to inject this infinite Run hack but it didnt worked (Crash my GTA)
(I know, it exists a faster way(0xB7CEE4) i try the longer way with Pointers because i want to follow a tutorial)

#include <windows.h>
#include <iostream>

using namespace std;

DWORD BasePointer = 0;  
#define Points 0x51c  
#define Point2 0x39c

bool State = false;   

void punkte()
{
if (State)
{
DWORD dwBasePointer = *(DWORD*)BasePointer;  
if (dwBasePointer != 0) 
{
DWORD dwPoints1 = *(DWORD*)(dwBasePointer + Points); 
DWORD &dwPoints = *(DWORD*)(dwPoints1 + Point2);
dwPoints = 1;  
 

}

}
else 
{
DWORD dwBasePointer = *(DWORD*)BasePointer; 
if (dwBasePointer != 0)  
{
DWORD dwPoints1 = *(DWORD*)(dwBasePointer + Points);
DWORD &dwPoints = *(DWORD*)(dwPoints1 + Point2);  

dwPoints = 0;

}
}
}

DWORD WINAPI HackThread(LPVOID unused)
{
DWORD ImageBase = (DWORD)"THREADSTACK0";  
BasePointer = ImageBase + -0x00001000;  
  

for (; ;)  //
{
punkte();  //unsere main funktion wird ausgeführt
if (GetAsyncKeyState(VK_F1) & 1)State = !State; // Mit F1 aktivieren und deaktivieren wir den Hack
Sleep(10);
}
}

BOOL WINAPI DllMain(HINSTANCE mod, DWORD DWORD_GRUND, LPVOID res)
{
switch (DWORD_GRUND)
{
case DLL_PROCESS_ATTACH: 
CreateThread(0, 0, &HackThread, 0, 0, 0);
break;
case DLL_PROCESS_DETACH:
MessageBoxA(0, "Not Loaded", "Info", 0); 
break;
}
return TRUE;
}
 
Joined
Dec 31, 2015
Messages
712
Reaction score
27
Can't really understand where you're grabbing pointer address, why var ImageBase is dword of "threadstack0" and why offset value is negative 0x1000 lol
Here should be the problem, fix it, and please use Code Template next time
 

0x_

Wtf I'm not new....
Administrator
Joined
Feb 18, 2013
Messages
1,118
Reaction score
166
1) Use the code BBCode.
2) What the fuck are you trying?
 

Siedler

Active member
Joined
Oct 21, 2013
Messages
34
Reaction score
1
0x688 said:
1) Use the code BBCode.
2) What the fuck are you trying?

Kurz auf deutsch:

1.Ich habe einen Pointerscan gemacht damit ich Adressen die noch darauf gepointet werden habe, weil ich nicht
wusste wie ich eine Adresse direkt bearbeiten kann. gta_sa + adresse ist nicht das was ich benutzte und ich brauche einen Handle,
deswegen habe ich den Handle so genannt (THREADSTACK0).

2. Im Pointerscan wurde mit THREADSTACK0 -00001000 angezeigt und ich hab nicht verstanden was ich machen sollte,
auf jeden fall war das eine Static addresse mit Offsets und ich dachte das das mit einem Minus Operatoren hin hauen könnte.

3. Ich habe 0 Ahung von Dlls, bis jetzt habe ich nur Executable Hacks gemacht :p

BTW. THREADSTACK0 + -0x00001000 + Offset1 + Offset2 == 0xB7CEE4 - [byte/boolean] Is infinite run



What is a BBcode?
 

0x_

Wtf I'm not new....
Administrator
Joined
Feb 18, 2013
Messages
1,118
Reaction score
166
I'll continue to list all my concerns in a nifty little list:

1) http://ugbase.eu/Thread-General-UGBASE-EU-Rules *- Read rule 1.4 I'll let this go trough this time tho
2) Whatever you're saying about "external hacks" is bullshit, as if you're experienced with external hacks you should have enough experience to know that "THREADSTACK0" is no handle or whatsoever especially if only casted to a unsigned long?
3) You can acquire the "handle" of your current process by using HMODULE hMod = GetModuleHandle(NULL); - https://msdn.microsoft.com/en-us/en-en/library/windows/desktop/ms683199(v=vs.85).aspx
 

Siedler

Active member
Joined
Oct 21, 2013
Messages
34
Reaction score
1
0x688 said:
I'll continue to list all my concerns in a nifty little list:

1) *- Read rule 1.4 I'll let this go trough this time tho
2) Whatever you're saying about "external hacks" is bullshit, as if you're experienced with external hacks you should have enough experience to know that "THREADSTACK0" is no handle or whatsoever especially if only casted to a unsigned long?
3) You can acquire the "handle" of your current process by using HMODULE hMod = GetModuleHandle(NULL); - https://msdn.microsoft.com/en-us/en-en/library/windows/desktop/ms683199(v=vs.85).aspx

1. Sry, dont know that.

I never sayd im experienced, the best hack of me was an smooth aimbot for cs:go, yep it was
a shitty code, without a perfect struct like your perfect codes, it was wpm yep but it was a HACK so
i coded a damn hack in external.
I never heard anything of Threadstack0!
Just found it in Pointerscan for this Addr(0xB7CEE4).
A friend sayd that gta_sa handle is (I know GetModuleHandle) but the Threadstack was the one 
that i need for pointing on this addr that i got (0xB7CEE4), in an executable you can basicly wpm on the Address that you got
but i dont know dll.

IM A beginner so calm down.
Search in Pointerscan for this adress 0xB7CEE4 and look
 

0x_

Wtf I'm not new....
Administrator
Joined
Feb 18, 2013
Messages
1,118
Reaction score
166
I still don't get what you're doing.
If you got your address which is in this case (0xB7CEE4)? why do you bother pointer scanning?

"(I know, it exists a faster way(0xB7CEE4) i try the longer way with Pointers because i want to follow a tutorial)"
Also if you get a lot of "threadstacks" your ptr scan is simply "wrong" increase the scan depth / level.

Also please give me more of your steps to reproduce.
 

Siedler

Active member
Joined
Oct 21, 2013
Messages
34
Reaction score
1
Can we Speak at discord and i try to describe what i mean?
or skype or pm at forum?
my english skillz are bad.
 

0x_

Wtf I'm not new....
Administrator
Joined
Feb 18, 2013
Messages
1,118
Reaction score
166
Like my signature implies I'm available via discord.
 
Top