1.4.10 updates
This commit is contained in:
@@ -84,11 +84,11 @@ void ServerConnection::handlePacketDisconnect(const std::string& message) {
|
||||
}
|
||||
|
||||
void ServerConnection::handlePacketHandshake(const std::string& data) {
|
||||
if(this->protocol.state != protocol::HANDSCAKE) LERROR("Protocol state mismatch");
|
||||
if(this->protocol.state != protocol::HANDSCHAKE) LERROR("Protocol state mismatch");
|
||||
if(data.length() < 3) LERROR("Invalid packet size");
|
||||
|
||||
if((uint8_t) data[0] != 0xAF || (uint8_t) data[1] != 0xFE) LERROR("Invalid handshake");
|
||||
if((uint8_t) data[2] != LICENSE_PROT_VERSION) LERROR("Invalid license protocol version. Please update TeaSpeak!");
|
||||
if((uint8_t) data[2] != 2) LERROR("Invalid license protocol version. Please update this client!");
|
||||
|
||||
auto key_length = be2le16(data.data(), 3);
|
||||
if(data.length() < key_length + 3) LERROR("Invalid packet size");
|
||||
|
||||
Reference in New Issue
Block a user