Valhalla Legends Archive

Programming => Battle.net Bot Development => Topic started by: Sorc.Polgara on July 02, 2004, 08:10 PM

Title: [VB6] SID_AUTH_INFO
Post by: Sorc.Polgara on July 02, 2004, 08:10 PM
It won't work for me...


Private Sub mnuConnect_Click()

   Dim sckHost As String
   Dim sckPort As Long

   sckHost = "useast.battle.net"
   sckPort = 6112
   
   ws.Connect sckHost, sckPort

End Sub

Private Sub ws_Connect()

   lstStatus.AddItem "Connected"

   SID_AUTH_INFO

End Sub

Private Sub SID_AUTH_INFO()

   Dim PBuf As New PacketBuffer

   PBuf.InsertDWORD 0
   PBuf.InsertNonNTString "68XI"
   PBuf.InsertNonNTString "RATS"
   PBuf.InsertDWORD &HC9
   PBuf.InsertDWORD 0
   PBuf.InsertDWORD 0
   PBuf.InsertDWORD 0
   PBuf.InsertDWORD 0
   PBuf.InsertDWORD 0
   PBuf.InsertNTString "USA"
   PBuf.InsertNTString "United States"
   PBuf.SendPacket ws, &H32
   
End Sub



I'm using the PacketBuffer Class by DarkMinion

I am recieving no response from the server.

The packet is suppose to be the SID_AUTH_INFO (0x50) B.Net packet

Quote
(DWORD)       Protocol ID (0)
(DWORD)       Platform ID
(DWORD)       Program ID
(DWORD)       Version Byte
(DWORD)       Product language
(DWORD)       Local IP for NAT compatibility*
(DWORD)       Time zone bias*
(DWORD)       Locale ID*
(DWORD)       Language ID*
(STRING)       Country abreviation
(STRING)       Country

Dunno what I doing wrong.

I used BnetDocs.... but I must be doing some wrong...
Title: Re:[VB6] SID_AUTH_INFO
Post by: BaDDBLooD on July 02, 2004, 08:14 PM
i believe it is 0x50 not 0x32 ( &H50 )
Title: Re:[VB6] SID_AUTH_INFO
Post by: MyndFyre on July 02, 2004, 11:05 PM
Quote from: BaDDBLooD on July 02, 2004, 08:14 PM
i believe it is 0x50 not 0x32 ( &H50 )

Hehehehe, 0x32 == 50d.  LoL.  ;)
Title: Re:[VB6] SID_AUTH_INFO
Post by: Sorc.Polgara on July 03, 2004, 03:15 PM
Ok, I fixed the message ID to &H50 but it still doesn't seem to work... I get no response. :\

I'm not quite sure what the version byte for StarCraft is... it changes so what is the current one atm?


Ummm  the BnetDocs and the BNLSProtocolSpec.txt say different things about the SID_AUTH_INFO packet...

BNLSProtocolSpec.txt

(DWORD) Protocol ID. Always 0.
(DWORD) Platform ID. Valid platform IDs are: 'IX86' (Intel x86), 'PMAC' (Macintosh generic), 'XMAC' (Macintosh OS-X).
(DWORD) Product ID. Valid product IDs are: 'STAR', 'SEXP', 'W2BN', 'D2DV', 'D2XP', 'JSTR', 'WAR3'.
(DWORD) Version byte.**
(DWORD) Product language.*
(DWORD) Local IP, for NAT compatibility.*
(LONG) Time zone bias multiplied by -60, for example, GMT-8 gets the value 480: (-8*-60).*
(DWORD) Locale ID. Value returned by GetSystemDefaultLCID.*
(DWORD) Language ID. Value returned by GetSystemDefaultLangID.*
(String) Country abbreviation, such as "USA".
(String) Country name, such as "United States".

* This field doesn't really matter and may just be 0.



BnetDocs

(DWORD)       Protocol ID (0)
(DWORD)       Platform ID
(DWORD)       Program ID
(DWORD)       Version Byte
(DWORD)       Product language
(DWORD)       Local IP for NAT compatibility*
(DWORD)       Time zone bias*
(DWORD)       Locale ID*
(DWORD)       Language ID*
(STRING)       Country abreviation
(STRING)       Country

*These fields can be set to zero without breaking logon.


The BNLSProtocolSpec.txt says that the Time zone bias is a (LONG) but BnetDocs says its a (DWORD)...
Title: Re:[VB6] SID_AUTH_INFO
Post by: GoSuGaMING on July 03, 2004, 03:20 PM
current verByte for sc = &C9 or 201 in Decimal ^^