BNCS Headers
BNCS stands for Battle.Net Chat Server and is the protocol that Blizzard's Battle.net enabled games use to communicate. Every BNCS message has the same header:
(BYTE) Always 0xFF
(BYTE) Message ID
(WORD) Message length, including this header
(VOID) Message Data
The BNCS protocol is aggresively enforced by Battle.net - at least, for clients - and violations of the protocol generally result in an IP ban.
When connecting to a BNCS server, you must first tell the server which protocol you wish to use. Some of the Protocol IDs are:
- Games: 0x01
- FTP: 0x02
- Chat: 0x03
Realm Headers
Battle.net's Realm Servers are what control Diablo II's realms. Realm (Sometimes referred to as MCP) message headers are
also always the same, albeit slightly different from BNCS's:
(WORD) Message length, including this header
(BYTE) Message ID
(VOID) Message Data
Violations of the MCP protocol are less severely enforced by MCP servers. If they IP ban at all, it is generally only for a few minutes.
D2GS Headers
D2GS stands for Diablo 2 Game Server. This constitutes the in-game protocol used by Diablo II. The D2GS protocol is somewhat more complicated than other Blizzard protocols - most D2GS messages have set lengths, and those that don't generally have some unique way of obtaining it. The headers are as follows (for decompressed messages):
(BYTE) Message ID
(VOID) Message Data
For compressed messages:
(BYTE) Message Size
(BYTE) Decompressed Message ID
(VOID) Message Data
Botnet Headers
Botnet is a system whereby bots can share information about users and send commands to eachother. It is also used by various bot authors
as a means of leak protection & statistics collection, and to administer BNLS & Webchannel, in addition to being a useful chat medium when
more privacy is needed than Battle.net allows. The headers are as follows:
(BYTE) Protocol Version (Currently 0x01)
(BYTE) Message ID
(WORD) Message Length, including this header
(VOID) Message Data
BNLS Headers
BNLS is the Battle.Net Logon Server, and can be used by bot authors to perform some of the computational tasks required during a Battle.net logon. It also allows
bot authors to obtain useful information such as the current version byte for a game client, and has provisions for BNCS server emulator authors.
It has the following headers:
(WORD) Message Length, including this header
(BYTE) Message ID
(VOID) Message Data
Warcraft III In-game Headers
Used by both ladder games and custom games, the format of these messages are nearly the same as BNCS packets. Every packet has the same header:
(BYTE) Always 0xF7
(BYTE) Message ID
(WORD) Message length, including this header
(VOID) Message Data
Specific message formats for Warcraft III in-game is not documented yet, but will be available in the near future.
Storm UDP Protocol
This protocol is defined and processed by functions within Storm.dll and is used for numerous games - namely, Diablo 1, Warcraft II: BNE, Starcraft, and Starcraft: Brood War.
(WORD) Checksum
(WORD) Header Length
(WORD) Seq1
(WORD) Seq2
(BYTE) CLS
(BYTE) Command
(BYTE) PlayerID
(BYTE) Resend
Checksum is performed by a storm function and is calculated on the whole message, starting at Header Length.
Header Length is the length of the entire message.
Seq1 is the sender's position in the outbound stream.
Seq2 is the most recently recieved message.
CLS is always a value from 0-2, 0 indicating that the message is processed by Storm, 1 for asynchronous data, 2 for synchronous data, both of which are passed onto the game client.
Command specifies the message type for CLS type zero, but is always zero otherwise.
PlayerID is the ID of the sending player.
Resend contains control flags.
Synchronous messages contain data that all clients must process on the same turn.
Other Battle.net protocol IDs are MCP to BNCS communication (0x04) and 0x06, which we know nothing about. At a guess, it is used for interserver synchronisation.
#6
User Comments:
Posted by Iarn on 29/11/04 08:30 |
It should be 0x04 now.
|
#230 |
Posted by UserLoser (Editor) on 30/09/03 06:48 |
(BYTE) StartPacket - always 0xF7
(BYTE) Packet ID
(WORD) Packet length, including this header
(VOID) Packet Data
To my knowledge, games are all clientclient, Battle.net servers are not involved at all, except creating/reporting/leaving a game.
|
#125 |
Posted by UserLoser (Editor) on 16/08/03 12:45 |
I sent in some information about UDP headers and the protocol...where is it?
|
#119 |
Posted by BNU-Camel on 12/02/03 10:24 |
how 'bout you just dont join sc games? :)
|
#30 |
Posted by Arta (Administrator) on 27/01/03 10:29 |
No, I've never done any research into that, and no one has offered to contribute the information.
If I get any public information on SC's ingame protocol I'll post it.
|
#17 |
Posted by Mesiah on 27/01/03 09:32 |
Lets try this again lol, do you have any info on UDP Protocol Headers?
|
#16 |
Posted by Etheran on 27/01/03 12:10 |
You forgot 0x2 for the blizzards ftp.
|
#9 |