UP!
Hey, I'm back. Well, I know someone who will bite me but I have good news (in my opninion). As you know, I started to learn how to code in C#, I'm in progress so I can't start such a brilliant thing on making any bot BUT, I keep coding in AutoIt and, I wanted to test something. Trying to receive packets from any game client and guess what... IT WORKED!
Okay well, this is not awesome maybe, but I was thinking... I tested my code on a out-dated client (5165), and I received a packet from it.
Code:
0x159456659772A5B599F933A514CB756F5F89B0229346F6E3D6003EA217C4786C5682BF2B9243F5E0D90535AB16C17F6D5987BA209D4CF8E1D00E30A011C272625088B1299C49FFE6DB033FA910CF71635B8DBC269F4AF2E7D2043AA613C874605286BB2F9E47F1E4D50931AF12C57B61558BB6249940F4E5DC023CA41DC67E665C8CBD2DCB9C7B22AD3B598BCCA9FDB368F7061D9B4EFEEBDE0836AA1FCC70645E8AB7239A4BFDE8D10D3DA31EC97765518FB2289544F0E9D80638A819CA7A6A5880B9219441F7EED30B37A118C7796B5385B42E9742FAEFDA0C32AE1BC07C685A8EB327964FF9ECDD0139A71ACD73695D83BE2C9148FCEDD40A34AC15CE766E865667F7778166672A3BB777C619A7BD8D5B62F0
This is ugly, horrible whatever you want but for me it's a start and that means "you will be able to do something" but here is my problem.... WHAT DOES THAT MEAN? I truly think that it is the encryption key's job, and now I need some help.
First of all, how can I have my encryption key, I've got the source associated to the client (to make a private server wich works)? Then, how can I use it with AutoIt (if you don't have codes, just some advices or infos on what is that encryption key or anything else which can help me a little bit) and finally, what will I have when the packet will get modified by the key?
Hope you will be able to help me! Thanks in advance!
PS : I tried to send an answer to the client and he crashed or exited itself, surely because my packet was wrong.
Here's my code :
Code:
#cs ----------------------------------------------------------------------------
AutoIt Version: 3.3.8.1
Author: itachi26
Script Function:
Template AutoIt script.
#ce ----------------------------------------------------------------------------
; Script Start - Add your code below here
TCPStartup()
$IP = @IPAddress2 ; "127.0.0.1"
$port = 9958
$socket = TCPListen($IP,$port)
If $socket = -1 Then Exit
$isConnected = -1
Do
$isConnected = TCPAccept($socket)
Sleep(10)
Until $isConnected <> -1
ToolTip("waiting for packets",5,0)
While 1
$recv = TCPRecv($isConnected,999999)
If $recv <> "" Then
ToolTip("Received packet : " & $recv,5,0)
IniWrite(@ScriptDir & "\test.ini",$recv,"lol","lol")
$answer = InputBox("","type an answer")
If $answer <> "" Then TCPSend($isConnected,$answer)
EndIf
WEnd
EDIT : Baxk again. Well, I'm getting some problems while coding my proxy. Here's how I manage to get work everything.
My proxy is listenning on my Hamachi adress, port 9957.
My server is setting-up on my Hamachi adress, port 9958
The client connects through my Hamachi adress, port 9957.
I lunch the client and put my username/pass, my proxy receives the packet and connect to the server, the server accepts the connexion, my proxy send its packet to the server. Then, the server answers, sends to my proxy its packet, my proxy gives to the client the datas. The client creates maps and finally, my character is on but... I don't receive packets anymore. Moreover, the console says I'm still online.
Any ideas? By the way, I'll try to fix it, I'm glad at the moment to receive something and trying to manage with haha!
EDIT 2 : Oh my gosh... It looks like the client doesn't need my proxy seriously. I can receive packet from the client, the server listenning on 9958 and the client connects to 9957, and when I switch-off my proxy, the client keeps working properly... Haha!
EDIT 3 : My bad, by sniffing packets, I realized that two more ports come-in. I'm gonna update my code and will see what's gonna happen.
If someone can think about my question on the encryption and AutoIt, it will be super cool! Thanks!
EDIT 4 : Alright! So, I worked harder and harder and here is where I am at the moment. My code is able to receive two connexions on the client : login/game sockets and two connexions on the server : login/game. I can play, hit, talk, wear buy well, everything without getting dced which that good in my opinion. My problem, can't do anything with those packets at the moment, also, it lags a little bit, Ithink that it's just my code who's note very optimized and because I'm using AutoIt and that is a very slow language.
Now, I need your help about the encryption part. I really don't know how does it work then, I need some advises and some explanations about it. I think I found everything in the server's source but it looks very hard to understand.
Thanks in advance!