diff --git a/src/pocketmine/Server.php b/src/pocketmine/Server.php index 47f3587a7..edbba95a8 100644 --- a/src/pocketmine/Server.php +++ b/src/pocketmine/Server.php @@ -636,6 +636,8 @@ class Server{ if($this->logger instanceof MainLogger){ $this->logger->logException($e); } + + $this->mainInterface->blockAddress($address, 600); } //TODO: add raw packet events } diff --git a/src/pocketmine/network/RakLibInterface.php b/src/pocketmine/network/RakLibInterface.php index 20e9c101c..c9b6627c2 100644 --- a/src/pocketmine/network/RakLibInterface.php +++ b/src/pocketmine/network/RakLibInterface.php @@ -188,10 +188,16 @@ class RakLibInterface implements ServerInstance, SourceInterface{ $logger->logException($e); } } + + $this->interface->blockAddress($this->players[$identifier]->getAddress(), 5); } } } + public function blockAddress($address, $timeout = 300){ + $this->interface->blockAddress($address, $timeout); + } + public function handleRaw($address, $port, $payload){ $this->server->handlePacket($address, $port, $payload); } diff --git a/src/raklib b/src/raklib index 2016c58c5..9a1c1868b 160000 --- a/src/raklib +++ b/src/raklib @@ -1 +1 @@ -Subproject commit 2016c58c531fec30ec095e9215d771a5ccabe4ce +Subproject commit 9a1c1868b34c2db546cad5895e5974e74ab24763