Valhalla Legends Forums Archive | Battle.net Bot Development | Diablo II Game Server Logon Sequence

AuthorMessageTime
Spilled[DW]
I Guess I'm a little confused on the sequence to the Game Server. I was told:
[quote]
C > S Connect()
S > C Accept()
S > C 0xAF (Compressed)  --  AF 01
C > S 0x68 (Login Data)
C > S 0x6D (Optional ping at this stage)
S > C 0x01
S > C 0x00
If Failed: S > C 0xB3
If Passed: S > C 0x02
C > S 0x6B
S > C Game Data
[/quote]


But....
http://bnetdocs.valhallalegends.com/content.php?Section=d&id=20

Is showing me Different. On top of that After i Send 0x68 when I Recieve 0xAF. I get a response of 0x01 from the Game Server, Is there any documentation on this anywhere that you could link me to? Thank everyone!
December 10, 2005, 8:54 AM
Ringo
Hmm, yeah your probly better off doing it like it says on bnet docs:
[code]
Private Sub sckD2GS_DataArrival(ByVal bytesTotal As Long)
    On Error Resume Next
    Dim Data As String
    sckD2GS.GetData Data, vbString
    If Data = Chr(&HAF) & Chr(1) Then
        'C > S 0x68
        'C > S 0x6D
    ElseIf Data = Chr(2) & Chr(&H5C) Then
        'C > S 0x6B
    Else
        'DoData data
    End If
End Sub
[/code]
Its also kinda documented here close to the top of the post.

And im not sure what 0x01 really is, but it can be ignored (its probly infomation about the game type, like hc/sc etc)
December 10, 2005, 8:19 PM
Spilled[DW]
Hrmm. Now that I have follow the sequence. When I Send 0x6A to the Game Server, It disconnects me.,

My sequence is like so:

Connect to Game Server.
S - C 0xAF
C - S 0x68
C - S 0x6D
S - C 0x5C
C - S 0x6A

When I Send 0x6A, I am Disconnected.,..

Heres a Packet Log:

5  Hide  Hide  2  Recv 
0000  AF 01                                              ..

6  Hide  Hide  50  Send 
0000  68 C7 97 01 11 27 03 04 0B 00 00 00 50 CC 5D ED    h....'......P.].
0010  B6 19 A5 91 00 53 70 69 6C 6C 65 64 2D 48 61 6D    .....Spilled-Ham
0020  6D 65 72 73 00 6D 2E 33 16 11 00 00 00 00 00 00    mers.m.3........
0030  00 00                                              ..

7  Hide  Hide  10  Recv 
0000  0A 7A 09 A5 F1 F7 FF FF FF FC                      .z........

8  Hide  Hide  2  Recv 
0000  02 5C                                              .\

9  Hide  Hide  1  Send 
0000  6A 


0x6D Is combining with 0x68, Could that be it? I know about the random Data at the end of 0x68 But my character name fills it so no random data is needed to be added.

Also what is:
7  Hide  Hide  10  Recv 
0000  0A 7A 09 A5 F1 F7 FF FF FF FC                      .z........

How should i responde to this packet? Is there any document u could link me to?

This should be sufficient ammount of Information to Pinpoint the Problem, If any more is needed just post back. Thanks in advance!
December 11, 2005, 6:44 AM
One-Way
you must send 0x6B not 0x6A....
December 11, 2005, 1:45 PM
Ringo
[quote author=Spilled[DW] link=topic=13472.msg137157#msg137157 date=1134283495]
0x6D Is combining with 0x68, Could that be it? I know about the random Data at the end of 0x68 But my character name fills it so no random data is needed to be added.

Also what is:
7  Hide  Hide  10  Recv 
0000  0A 7A 09 A5 F1 F7 FF FF FF FC                      .z........

How should i responde to this packet? Is there any document u could link me to?
[/quote]
Like One-Way said, you need to send 0x6B rather than 0x6A, somthing that changed in 1.11, but i dont think krad fully updated bnet docs.

You also dont need to respond to 0A 7A 09 A5 F1 F7 FF FF FF FC
You should also decompress it, because the only 2 compressed messages to capture and respond to are AF 01 and 02 5C.
I think because 0x68 and 0x6D were stacked, it caused to server to do the same with the responce.
0x01 and 0x00 always come together, but that also has the 0x6D ping responce compressed into it as well:
[code]
01 00 04 00 10 00 01 00                              ........

00                                                   .

8F 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00      ?...............
00 00 00 00 00 00 00 00 00 00 00                     ...........
[/code]
All 3 of them messages can safely be ignored, so you dont need to respond to them at all.
December 11, 2005, 6:37 PM
Spilled[DW]
Hrmm, But i keep getting disconnected fromt he game server after in game about 1 minute at the most when i send 0x6D every 5 seconds. Any ideas?
December 11, 2005, 10:10 PM
kamakazie
[quote author=Spilled[DW] link=topic=13472.msg137191#msg137191 date=1134339029]
Hrmm, But i keep getting disconnected fromt he game server after in game about 1 minute at the most when i send 0x6D every 5 seconds. Any ideas?
[/quote]

Is warden activated? If it is and you're not responding to it, then you'll be kicked out.
December 11, 2005, 10:18 PM
Infamous
I'm having the same problem with my bot, keep getting disconnected after 30s. Has anyone figured out how to decode the warden packet or has got any information on packet 0x66?

Thanks.
December 11, 2005, 11:07 PM
l2k-Shadow
[quote author=Spilled[DW] link=topic=13472.msg137191#msg137191 date=1134339029]
Hrmm, But i keep getting disconnected fromt he game server after in game about 1 minute at the most when i send 0x6D every 5 seconds. Any ideas?
[/quote]

I told you this would happen on AIM like three times... I love it when people just don't listen
December 12, 2005, 12:08 AM
Ringo
[quote author=teK link=topic=13472.msg137197#msg137197 date=1134342428]
I'm having the same problem with my bot, keep getting disconnected after 30s. Has anyone figured out how to decode the warden packet or has got any information on packet 0x66?

Thanks.
[/quote]
All i know is, that if you send 2 0x66 packets, both with a 1 byte payload of 0x01, the server will send you the 1st chunk of the warden module.
Then if you send another 2 with 0x01, the server sends you the next chunk.
But that still doesnt stop you from droping :(
December 12, 2005, 2:20 AM
Spilled[DW]
[quote author=dxoigmn link=topic=13472.msg137192#msg137192 date=1134339514]
[quote author=Spilled[DW] link=topic=13472.msg137191#msg137191 date=1134339029]
Hrmm, But i keep getting disconnected fromt he game server after in game about 1 minute at the most when i send 0x6D every 5 seconds. Any ideas?
[/quote]

Is warden activated? If it is and you're not responding to it, then you'll be kicked out.
[/quote]

Hrmm, Do you have any information on Warden? Cuz if so, we would like to hear it since no body has gotten past it. Personally im Interested in doing some research on this and how i would get past the check.
December 12, 2005, 4:14 AM

Search