mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-05 01:16:15 +00:00
NetworkSession: Send less information to clients on error disconnects
in particular, the information from VerifyLoginTask shouldn't be sent to clients, as it could contain sensitive information. This change only affects disconnection screens. The server log shows the same amount of information as before (though formatted differently in some cases).
This commit is contained in:
@ -85,8 +85,10 @@ class ResourcePacksPacketHandler extends PacketHandler{
|
||||
}
|
||||
|
||||
private function disconnectWithError(string $error) : void{
|
||||
$this->session->getLogger()->error("Error downloading resource packs: " . $error);
|
||||
$this->session->disconnectWithError(KnownTranslationFactory::disconnectionScreen_resourcePack());
|
||||
$this->session->disconnectWithError(
|
||||
reason: "Error downloading resource packs: " . $error,
|
||||
disconnectScreenMessage: KnownTranslationFactory::disconnectionScreen_resourcePack()
|
||||
);
|
||||
}
|
||||
|
||||
public function handleResourcePackClientResponse(ResourcePackClientResponsePacket $packet) : bool{
|
||||
|
Reference in New Issue
Block a user