| Type |
Name |
Dependency |
Comment |
| OGP Header (Query) |
| UINT32 |
Prefix |
|
Value: 0xFFFFFFFF |
| SzString |
|
Value: "OGP" (4 bytes incl. 0 byte) |
| UINT8 |
HeadSize |
|
Size in bytes of the ogp header including this field but without the prefix. |
| UINT8 |
Type |
|
0x00 - Ping
0x01 - Default query v1
0x02 - (Rcon)
0x03 - Master Server Uplink (answer only)
0xFF - Error (answer only)
|
| VarBitArray |
HeadFlags |
|
Bit 0.0: bAnswer = 0
Bit 0.1: bChallengeNumber
Bit 0.2: bRequestID
Bit 0.3: bSplit
Bit 0.4: bUTF8
The server ignores the query if bAnswer is set.
The bUTF8 fields indicates the character encoding of all strings used within the protocol. In general OGP uses the unicode character set. If bUTF8 is not set only the lower 256 unicode number could be encoded which are identical to the Latin-1 or ISO/IEC 8859-1 character encoding. Otherwise the full unicode charset is available and all strings are UTF-8 encoded.
A client indicates by settings the bUTF8 flag that it supports bUTF8. In that case the server is free to choose the character encoding. Otherwise it must answer in Latin-1.
|
| UINT32 |
ChallengeNumber |
HeadFlags.bChallengeNumber |
The challenge number to query the server. If the number is wrong or you don't specify one, you'll get one per answer packet. Send a challenge number of 0 to request a new one.
OGP uses the challenge number mechanism to prevent DDoS attacks using ip spooling. It is ip dependent and can change at any time.
The number is not mandatory for every ogp service and depends on the server implementation.
|
| UINT32 |
RequestID |
HeadFlags.bRequestID |
User definied ID to associate an answer packet with a query and to detect duplicated UDP packets. If RequestID = 0 the server will choose a request id. |
| UINT16 |
MaxBytesPerPacket |
HeadFlags.bSplit |
Maximum number of bytes a packet may contain. Set to 0 to deactivate OGP splitting mechanism and use the splitting mechansim of the underlying protocol.
The minimum value is 500 (if not set to 0). The default value is 0.
|