EMO Style ForumPro - Hos Geldiniz
 [Tut] C++ Trainer Uyeols10

Join the forum, it's quick and easy

EMO Style ForumPro - Hos Geldiniz
 [Tut] C++ Trainer Uyeols10
EMO Style ForumPro - Hos Geldiniz
Would you like to react to this message? Create an account in a few clicks or log in to continue.
Giriş yap

Şifremi unuttum

Istatistikler
Toplam 203 kayıtlı kullanıcımız var
Son kaydolan kullanıcımız: crayzboy76

Kullanıcılarımız toplam 1186 mesaj attılar bunda 862 konu
Tarıyıcı
 Kapı
 Indeks
 Üye Listesi
 Profil
 SSS
 Arama
Arama
 
 

Sonuç :
 


Rechercher çıkıntı araştırma

RSS akısı


Yahoo! 
MSN 
AOL 
Netvibes 
Bloglines 


Anahtar-kelime

loot  pointer  kutu  

Kimler hatta?
Toplam 3 kullanıcı online :: 0 Kayıtlı, 0 Gizli ve 3 Misafir

Yok

[ Bütün listeye bak ]


Sitede bugüne kadar en çok 217 kişi C.tesi Tem. 29, 2017 1:46 am tarihinde online oldu.
En son konular
» İnternetten Para Kazandıran Oyun ! Ödeme Alt Limiti Yok ! DEV KONU
 [Tut] C++ Trainer I_icon_minitimeCuma Ağus. 29, 2014 8:33 am tarafından Hello EMO

» goldenchase.net maden yaparak para kazanma
 [Tut] C++ Trainer I_icon_minitimeCuma Ağus. 29, 2014 8:18 am tarafından Hello EMO

» etichal hacker görsel egitim seti
 [Tut] C++ Trainer I_icon_minitimeÇarş. Ağus. 06, 2014 4:57 am tarafından Hello EMO

» KO TBL Source C#
 [Tut] C++ Trainer I_icon_minitimePtsi Ara. 09, 2013 6:36 am tarafından Hello EMO

» x86 Registers
 [Tut] C++ Trainer I_icon_minitimeC.tesi Ağus. 24, 2013 5:02 am tarafından Hello EMO

» [Tutorial] Pegando Address, Pointers de WYD
 [Tut] C++ Trainer I_icon_minitimeÇarş. Tem. 10, 2013 7:25 am tarafından Hello EMO

» [Tutorial] Pegando Address, Pointers de CS Metodo²
 [Tut] C++ Trainer I_icon_minitimeÇarş. Tem. 10, 2013 7:23 am tarafından Hello EMO

» [Tutorial] Aprendendo basico deASM OLLYDBG
 [Tut] C++ Trainer I_icon_minitimeÇarş. Tem. 10, 2013 7:22 am tarafından Hello EMO

» Basic C# DLL injector
 [Tut] C++ Trainer I_icon_minitimePtsi Tem. 08, 2013 7:48 am tarafından Hello EMO

Reklam

[Tut] C++ Trainer

Aşağa gitmek

 [Tut] C++ Trainer Empty [Tut] C++ Trainer

Mesaj tarafından Hello EMO C.tesi Ara. 04, 2010 1:29 pm

[quote name='n0n3' timestamp='1210609440' post='10278']
Today we're gonna learn how to make your very own trainer in C++, without DLL injection of any sort. Smile


Knowledge needed/optional:

Basic C++ coding "skillZ"

Basic understanding of the PE and finding an address with Cheat Engine ;P


Ok let's get to it then.

Our target today is Windows's pinball game (start->run->"pinball")


First, declarations.


Kod:


   HWND hWnd;

   DWORD dwID;

   HANDLE hProcess;


hWnd = Window Handle.

dwID = Process ID.

hProcess = Process Handle.


Defined in windows.h btw, so #include


Let's recover the window handle then.


Kod:


   hWnd = FindWindow(NULL, "3D Pinball for Windows - Space Cadet");



FindWindow's return value is the HANDLE of the window.

For more info goto msdn. (google->msdn)


Let's recover the process id.


Kod:


   GetWindowThreadProcessId(hWnd, &dwID);


For more info goto msdn, this isn't difficult at all.

We recovered the process's ID.


Next, process handle.

Kod:


hProcess = OpenProcess(PROCESS_ALL_ACCESS, NULL, dwID);


Process security and access rights - Process Security and Access Rights (Windows)


PROCESS_ALL_ACCESS, hmm, I wonder what that might be.

Anyways, we don't need the second argument, and the third argument is the process ID.

If function works successfuly returned value is the process handle, which is exactly what we need.


Error handling would look like this:

Kod:


hProcess = OpenProcess(PROCESS_ALL_ACCESS, NULL, dwID);

if(hProcess == NULL)

      whatever //error



Here comes the fun part ;D


Kod:


int value = 1000000;

WriteProcessMemory(hProcess, (LPVOID) 0x00C20C62, (LPVOID) &value, sizeof(&value), NULL);


hProcess = Process handle.

(LPVOID) typecasting - needed.

0x00C20C62 - "Score" address in pinball.

(LPVOID) typecasting - needed.

&value - pointer to the value integer (1000000)

Next argument is number of bytes to be written (size)

So we use sizeof for it to work well.


We don't need the next parameter.


Full program will look like this:

Kod:


#include <iostream>

#include <windows.h>


using namespace std;


int main()

{

   HWND hWnd;

   DWORD dwID;

   HANDLE hProcess;


   hWnd = FindWindow(NULL, "3D Pinball for Windows - Space Cadet");


   GetWindowThreadProcessId(hWnd, &dwID);

   hProcess = OpenProcess(PROCESS_ALL_ACCESS, NULL, dwID);


   int value = 1000000;

   

   WriteProcessMemory(hProcess, (LPVOID) 0x00C20C62, (LPVOID) &value, sizeof(&value), NULL);

   return 0;

}



Guess what, it works, and you've just made a pinball trainer in C++ Smile

I'm so proud of you ;')


Enjoy Very Happy
[/quote]
Hello EMO
Hello EMO
EMO Team
EMO Team

Cinsiyet : Erkek
Burçlar : Yay
Yılan
Mesaj Sayısı : 935
Puan : 384393
Rep Puanı : 18
Doğum tarihi : 28/11/89
Kayıt tarihi : 21/07/09
Yaş : 34
Nerden : EMO WorlD
İş/Hobiler : RCE Student / Game Hacking / Learn Beginner C#,C++,Delphi
Lakap : EMO

https://emostyle.yetkinforum.com

Sayfa başına dön Aşağa gitmek

Sayfa başına dön

- Similar topics

 
Bu forumun müsaadesi var:
Bu forumdaki mesajlara cevap veremezsiniz