• Welcome to Valhalla Legends Archive.
 

Legacy logon system

Started by Ribose, May 11, 2008, 12:51 PM

Previous topic - Next topic

Ribose

So I decided I might try implementing the old legacy logon system. I noticed from topics that JSTR, SSHR, DSHR, DRTL, and W2BN all use lockdown as well as this legacy system. So I started with JSTR:
[1:07:29 PM] [BNET] Connecting to useast.battle.net..
[1:07:29 PM] [BNET] Connected!
[1:07:29 PM] [BNET] SENT BYTE 0x1
[1:07:29 PM] [BNET] SENT PACKET 0x1E SID_CLIENTID2:
0000   ff 1e 2f 00 00 00 00 00  00 00 00 00 00 00 00 00    ÿ./.............
0010   00 00 00 00 00 00 00 00  4e 61 74 65 27 73 20 43    ........Nate's C
0020   6f 6d 70 75 74 65 72 00  4e 61 74 65 00             omputer.Nate.
[1:07:29 PM] [BNET] SENT PACKET 0x12 SID_LOCALEINFO:
0000   ff 12 41 00 40 21 94 7e  89 b3 c8 01 40 21 94 7e    ÿ.A.@!.~..È.@!.~
0010   89 b3 c8 01 f0 00 00 00  09 04 00 00 09 04 00 00    ..È.ð...........
0020   09 04 00 00 65 6e 00 55  6e 69 74 65 64 20 53 74    ....en.United St
0030   61 74 65 73 00 55 53 41  00 45 6e 67 6c 69 73 68    ates.USA.English
0040   00                                                  .
[1:07:29 PM] [BNET] SENT PACKET 0x6 SID_STARTVERSIONING:
0000   ff 06 14 00 36 38 58 49  52 54 53 4a 0a 00 00 00    ÿ...68XIRTSJ....
0010   00 00 00 00                                         ....
[1:07:29 PM] [BNET] RECIEVED PACKET 0x5 SID_CLIENTID:
0000   ff 05 14 00 00 00 00 00  00 00 00 00 00 00 00 00    ÿ...............
0010   00 00 00 00                                         ....
[1:07:29 PM] [BNET] Requesting logon authorization..
[1:07:29 PM] [BNET] RECIEVED PACKET 0x1D SID_LOGONCHALLENGEEX:
0000   ff 1d 0c 00 3c 3e 5b 00  b4 78 77 bc                ÿ...<>[.´xw.
[1:07:29 PM] [BNET] RECIEVED PACKET 0x25 SID_PING:
0000   ff 25 08 00 19 68 28 84                              ÿ%...h(.
[1:07:29 PM] [BNET] SENT PACKET 0x25 SID_PING:
0000   ff 25 08 00 19 68 28 84                              ÿ%...h(.
[1:07:29 PM] [BNET] RECIEVED PACKET 0x6 SID_STARTVERSIONING:
0000   ff 06 1c 00 00 20 58 7d  99 cb c6 01 76 65 72 2d    ÿ.... X}.ËÆ.ver-
0010   49 58 38 36 2d 30 2e 6d  70 71 00 00                IX86-0.mpq..
[1:07:29 PM] [BNET] Received authorization challenge!
[1:07:31 PM] [BNET] SENT PACKET 0x7 SID_REPORTVERSION:
0000   ff 07 29 00 36 38 58 49  52 54 53 4a 0a 00 00 00    ÿ.).68XIRTSJ....
0010   00 00 00 01 04 11 5e 89  3e 62 3a 5c 08 e3 46 1b    ......^.>b:\.ãF.
0020   c8 95 78 09 ac 87 ff 7c  00                          È.x.¬.ÿ|.
[1:07:31 PM] [BNET] Answering authorization challenge..
[1:07:31 PM] [BNET] RECIEVED PACKET 0x7 SID_REPORTVERSION:
0000   ff 07 08 01 00 00 00 00  00 00 63 72 6f 20 54 72    ÿ.........cro Tr
0010   49 20 77 61 6e 74 20 64  65 6d 6f 6e 20 6f 6e 20    I want demon on
0020   6d 79 20 74 65 61 6d 00  20 54 65 6d 70 6c 65 20    my team. Temple
0030   55 53 45 61 73 74 00 4c  6f 44 20 50 61 6c 61 64    USEast.LoD Palad
0040   69 6e 20 54 72 61 64 69  6e 67 20 55 53 45 61 73    in Trading USEas
0050   74 00 4c 6f 44 20 53 6f  72 63 65 72 65 73 73 20    t.LoD Sorceress
0060   54 6f 77 65 72 20 55 53  45 61 73 74 00 4c 6f 44    Tower USEast.LoD
0070   20 53 6f 72 63 65 72 65  73 73 20 54 72 61 64 69     Sorceress Tradi
0080   6e 67 20 55 53 45 61 73  74 00 4c 6f 49 62 62 00    ng USEast.LoIbb.
0090   ff 22 00 10 8c 27 ab 00  01 00 c0 6f 03 00 c0 6f    ÿ"...'«...Ào..Ào
00a0   49 62 62 00 80 27 ab 00  80 27 ab 00 01 00 00 00    Ibb..'«..'«.....
00b0   20 f1 ce 02 e8 f0 ce 02  40 5f 1c 12 40 39 7e 0b     ñÎ.èðÎ.@_..@9~.
00c0   c8 f1 ce 02 c4 f3 40 00  00 00 00 00 01 00 00 00    ÈñÎ.Äó@.........
00d0   02 00 00 00 b4 f1 ce 02  d4 f0 ce 02 00 00 00 00    ....´ñÎ.ÔðÎ.....
00e0   00 00 00 00 c8 00 00 00  0a 00 00 00 50 58 32 44    ....È.......PX2D
00f0   55 53 45 61 73 74 2c 49  42 42 2c 84 80 39 01 01    USEast,IBB,..9..
0100   01 01 0f ff 5d 02 02 ff                              ...ÿ]..ÿ
[1:07:31 PM] [BNET] Authorization challenge failed. Game version is invalid!
[1:07:31 PM] [BNET] Disconnected!

First thing I noticed is that the value string in 0x06 SID_STARTVERSIONING is blank, which is odd.
Then I looked at the 0x07 SID_REPORTVERSION. There's lots of random text absolutely nothing like the documentation says... Every time I connect, there are different random messages in that packet from "Make a new channel." to "SBCC IS SEXAY!!!!!!" as if I'm seeing some channel.

Well I just tried SSHR, DSHR, and DRTL, and I can get on... but what am I doing wrong with JSTR (and potentially W2BN, but I don't have means to test that)?
~Ribose

UserLoser

#1
search, this has been brought up tons of times in the past

also that SID_LOCALEINFO just doesn't look right

Ribose

Quote from: UserLoser on May 11, 2008, 01:04 PM
search, this has been brought up tons of times in the past

also that SID_LOCALEINFO just doesn't look right
I have searched, and using this style (although I forgot SID_SYSTEMINFO, lol) all the other legacy clients work, but not this one.
Quote from: UserLoser. on April 11, 2004, 10:06 AM
I don't have Japan Starcraft, but from the looks of battle.snp:

This *may* be incorrect:

C->S 0x1E (SID_CLIENTID2)
C->S 0x12 (SID_LOCALEINFO)
C->S 0x2B (SID_SYSTEMINFO)
C->S 0x06 (SID_STARTVERSIONING)
S->C 0x25 (SID_PING)
C->S 0x25 (SID_PING)
S->C 0x28 (SID_LOGONCHALLENGE)
S->C 0x06 (SID_STARTVERSIONING)
C->S 0x07 (SID_REPORTVERSION)
S->C 0x07 (SID_REPORTVERSION)
C->S 0x30 (SID_CDKEY)
S->C 0x30 (SID_CDKEY)
C->S 0x29 (SID_LOGONRESPONSE)
S->C 0x29 (SID_LOGONRESPONSE)

@SID_LOCALEINFO yea, i didn't feel like trying to figure out what to really put there. Once it works, I'll look into bettering that. Besides if I did it wrong to the point where it wouldn't let me pass, wouldn't I be IP-banned?
~Ribose

Ringo

Quote from: Ribose on May 11, 2008, 12:51 PM
First thing I noticed is that the value string in 0x06 SID_STARTVERSIONING is blank, which is odd.
The server does that when it has no checkrevision values on file for the version you logged on with, so check your version byte is within a valid range.

Also with the 0x07 thing, its just a server glitch, just parse what you need and ignore anything past that, since its just some random memory chunk.

Ribose

Lol, thanks, it was just a verbyte override option problem. 0x0A != 0xA9... fixed.
~Ribose

Barabajagal

When doing some tests with my own BNCServer (Battle.net Chat Server), the client apparently requires that extra data... I'm not sure why.
And if you happen to want SYSTEMINFO, UL did a favor to me and reversed it a while ago... http://forum.valhallalegends.com/index.php?topic=16255.0