2.2.1.2 DN_INTERNAL_MESSAGE_PLAYER_CONNECT_INFO_EX
This is the first message passed into a host/server to initiate the connect sequence.
Note This packet is an extended version of the DN_INTERNAL_MESSAGE_PLAYER_CONNECT_INFO packet for DirectPlay 9 that includes the dwAlternateAddressDataOffset, dwAlternateAddressDataSize, and alternateAddressData fields. If the value of the dwDNETVersion field is 7 or greater, the message is DN_INTERNAL_MESSAGE_PLAYER_CONNECT_INFO_EX; otherwise, if it is less than 7, the message is DN_INTERNAL_MESSAGE_PLAYER_CONNECT_INFO. The host/server has to recognize both messages, as clients/peers can send in either type of message depending on the client/peer version.
|
|
|
|
|
|
|
|
|
|
1 |
|
|
|
|
|
|
|
|
|
2 |
|
|
|
|
|
|
|
|
|
3 |
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
dwPacketType |
|||||||||||||||||||||||||||||||
dwFlags |
|||||||||||||||||||||||||||||||
dwDNETVersion |
|||||||||||||||||||||||||||||||
dwNameOffset |
|||||||||||||||||||||||||||||||
dwNameSize |
|||||||||||||||||||||||||||||||
dwDataOffset |
|||||||||||||||||||||||||||||||
dwDataSize |
|||||||||||||||||||||||||||||||
dwPasswordOffset |
|||||||||||||||||||||||||||||||
dwPasswordSize |
|||||||||||||||||||||||||||||||
dwConnectDataOffset |
|||||||||||||||||||||||||||||||
dwConnectDataSize |
|||||||||||||||||||||||||||||||
dwURLOffset |
|||||||||||||||||||||||||||||||
dwURLSize |
|||||||||||||||||||||||||||||||
guidInstance (16 bytes) |
|||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
guidApplication (16 bytes) |
|||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
dwAlternateAddressDataOffset |
|||||||||||||||||||||||||||||||
dwAlternateAddressDataSize |
|||||||||||||||||||||||||||||||
alternateAddressData (variable) |
|||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
url (variable) |
|||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
connectData (variable) |
|||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
Password (variable) |
|||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
data (variable) |
|||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
name (variable) |
|||||||||||||||||||||||||||||||
... |
dwPacketType (4 bytes): A 32-bit field that contains the packet type.
-
Value
Meaning
DN_MSG_INTERNAL_PLAYER_CONNECT_INFO
0x000000C1
Sends client/peer connection information to the server/host.
dwFlags (4 bytes): A 32-bit field that specifies the connect flags.
-
Value
Meaning
DP_OBECT_TYPE_CLIENT
0x00000002
Connecting application is a client.
DN_OBJECT_TYPE_PEER
0x00000004
Connecting application is a peer.
dwDNETVersion (4 bytes): A 32-bit field that specifies the DirectPlay version.
-
Value
Meaning
0x00000007
DirectX 9.0
0x00000008
DirectX 9.0
dwNameOffset (4 bytes): A 32-bit field that provides the offset from the end of dwPacketType of the connecting application's name field. If dwNameOffset is 0, the packet does not include name data.
dwNameSize (4 bytes): A 32-bit field that specifies the size, in bytes, of the data in the name field. If dwNameOffset is set to 0, dwNameSize SHOULD also be 0. If dwNameOffset is not 0, dwNameSize SHOULD also not be 0.
dwDataOffset (4 bytes): A 32-bit field that specifies the offset from the end of dwPacketType of the data field. If dwNameOffset is 0, the packet does not include application data.
dwDataSize (4 bytes): A 32-bit field that specifies the size, in bytes, of the data field. If dwDataOffset is set to 0, dwDataSize SHOULD also be 0. If dwDataOffset is not 0, dwDataSize SHOULD also not be 0.
dwPasswordOffset (4 bytes): A 32-bit field that specifies the offset from the end of dwPacketType of the Password field.
dwPasswordSize (4 bytes): A 32-bit field that specifies the size, in bytes, of the password. If dwPasswordOffset is set to 0, dwPasswordSize SHOULD also be 0. If dwPasswordOffset is not 0, dwPasswordSize SHOULD also not be 0.
dwConnectDataOffset (4 bytes): A 32-bit field that specifies the offset from the end of dwPacketType of the connectData field. If dwConnectDataOffset is 0, the packet does not include connection data.
dwConnectDataSize (4 bytes): A 32-bit field that specifies the size, in bytes, of the connectData field. If dwConnectDataOffset is 0, dwConnectDataSize SHOULD also be 0. If dwConnectDataOffset is not 0, dwConnectDataSize SHOULD also not be 0.
dwURLOffset (4 bytes): A 32-bit field that specifies the offset from the end of dwPacketType to the url field. If dwURLOffset is 0, the packet does not include the client URL. This URL represents the address of the client/peer that is connecting to the game session.
dwURLSize (4 bytes): A 32-bit field that specifies the size, in bytes, of the url field. If dwURLOffset is 0, dwURLSize SHOULD also be 0. If dwURLOffset is not 0, dwURLSize SHOULD also not be 0.
guidInstance (16 bytes): A 128-bit field that contains the GUID that identifies the particular instance of the server/host application to which the client/peer is attempting to connect. Each instance of a DirectPlay server/host application generates a new unique GUID each time the application hosts a new game session. In order for the client/peer to connect, the value of guidInstance MUST match the value of the GUID instance defined on the server/host or the value MUST be all zeroes. If a different, nonzero GUID instance value is specified, the recipient MUST send a DN_CONNECT_FAILED message with the result code DPNERR_INVALIDINSTANCE (0x80158380) and terminate the [MC-DPL8R] connection. For information on how a client/peer retrieves the value of the GUID instance defined on the server/host, see the description of the ApplicationInstanceGUID field in the EnumResponse message defined in [MC-DPLHP] section 2.2.2.
guidApplication (16 bytes): A 128-bit field that specifies the application's assigned GUID. This is the unique identifier for the specific application, not per instance.
dwAlternateAddressDataOffset (4 bytes): A 32-bit field that specifies the offset from the end of dwPacketType to the alternateAddressData field. If dwAlternateAddressDataOffset is 0, the packet does not include the alternate address data.
dwAlternateAddressDataSize (4 bytes): A 32-bit field that specifies the size, in bytes, of the alternateAddressData field. If dwAlternateAddressDataOffset is set to 0, dwAlternateAddressDataSize SHOULD also be 0. If dwAlternateAddressDataOffset is not 0, dwAlternateAddressDataSize SHOULD also not be 0.
alternateAddressData (variable): A variable-length field that specifies alternative address data used to connect the client. This field's position is determined by dwAlternateAddressDataOffset and the size stated in dwAlternateAddressDataSize. The addresses that are passed into the alternateAddressData field are formatted via the DN_ALTERNATE_ADDRESS structure. Because DN_ALTERNATE_ADDRESS contains its own size, multiple alternate addresses can be passed in by appending the DN_ALTERNATE_ADDRESS structures together. However, the maximum number of alternate addresses that can be passed in at a single time is limited to 12.
url (variable): A variable-length field that contains a 0-terminated byte character array that specifies the client URL. This field's position is determined by dwURLOffset and the size stated in dwURLSize. It is defined in DN_ADDRESSING_URL.
connectData (variable): A variable-length field that contains a byte array that provides the connection data. This field's position is determined by dwConnectDataOffset and the size stated in dwConnectDataSize.
Password (variable): A variable-length field that contains a 0-terminated wide character array that specifies the application password data. This field's position is determined by dwPasswordOffset and the size stated in dwPasswordSize. This data is passed in clear text to the protocol layer.
data (variable): A variable-length field that contains a byte array that specifies the application data. This field's position is determined by dwDataOffset and the size stated in dwDataSize.
name (variable): A variable-length field that contains a 0-terminated wide character array that specifies the client/peer name. This field's position is determined by dwNameOffset and the size stated in dwNameSize.