diff --git a/src/pocketmine/network/mcpe/protocol/LoginPacket.php b/src/pocketmine/network/mcpe/protocol/LoginPacket.php index 28a09b742..bad35b06b 100644 --- a/src/pocketmine/network/mcpe/protocol/LoginPacket.php +++ b/src/pocketmine/network/mcpe/protocol/LoginPacket.php @@ -163,6 +163,9 @@ class LoginPacket extends DataPacket{ $this->xuid = $claims["extraData"]["XUID"]; } } + if(!$hasExtraData){ + throw new \UnexpectedValueException("'extraData' not found in chain data"); + } $this->clientDataJwt = $buffer->get($buffer->getLInt()); $clientData = Utils::getJwtClaims($this->clientDataJwt);