metin2 packet func

12/20/2009 16:54 lordzio#1
Hello guys!
I'm trying to make a prog for sending packets.
First thing i thought to do was find a crypt function.
I have found interesting routine:
[Only registered and activated users can see links. Click Here To Register...]

But i can't figure what parameters ECX and EAX are for.

[Only registered and activated users can see links. Click Here To Register...]

EDI seems to be a packet size.

[Only registered and activated users can see links. Click Here To Register...]

ECX seems to be a pointer to a const value, it doesn't change when i send different packets.

[Only registered and activated users can see links. Click Here To Register...]

EDX is pointer to RAW data of my packet(i've typed in chat "hello elite pvpers")

[Only registered and activated users can see links. Click Here To Register...]

and this one gives me a headache, firstly i thought it's a pointer to crypted data, but what for? dunno what it can be, maybe a key to crypt? no idea..
If some1 knows please help me:P

Best regards,
Lordzio.
12/20/2009 17:03 ms​#2
Nice to see that there are not only leechers in the Metin2-Section. :p

1. parameter is a pointer to the encrypted data.
2. parameter is, as you have already found out, a pointer to the unencrypted data.
3. parameter is the length of the packet.
4. parameter is a pointer to the encryption key. Every time you log-in the client generates a new one encrypts all packets with it.

Furthermore the function's return value (stored in EAX) contains the length of the encrypted data.
12/20/2009 17:07 lordzio#3
Quote:
Originally Posted by Disconnect View Post
Nice to see that there are not only leechers in the Metin2-Section. :p

1. parameter is a pointer to the encrypted data.
2. parameter is, as you have already found out, a pointer to the unencrypted data.
3. parameter is the length of the packet.
4. parameter is a pointer to the encryption key. Every time you log-in the client generates a new one encrypts all packets with it.

Furthermore the function's return value (stored in EAX) contains the length of the encrypted data.

thx mate, that reply was really fast :) now i'll try to implement it in c++.
12/20/2009 17:09 ms​#4
No Problem. ;)
If you have further questions feel free to message me. But add me to your buddy list first cos I've blocked other PMs.
12/20/2009 17:23 alec1993#5
kann mir das jmd auf deutsch erklären xD bitte der bekommt auch thx wenn es kein google tranlator deutsch ist
12/20/2009 18:21 Necroface#6
Wie ist er in Client rein gekommen wie amcht man das?
12/20/2009 18:40 lordzio#7
Quote:
Originally Posted by Necroface View Post
Wie ist er in Client rein gekommen wie amcht man das?
I'm using polish client ( sorry if i understood u wrong, i know only Polish and English(badly) languages )
09/16/2011 14:55 MykroB#8
Hello! have you succeded in creating that packet prog?
09/16/2011 15:58 noahrmal#9
Look at the date :o 2Years #reported because of pushing old threads.