mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-06 09:56:06 +00:00
Use built-in random_bytes functionality
This commit is contained in:
@ -175,7 +175,7 @@ LICENSE;
|
||||
echo "[?] " . $this->lang->rcon_enable . " (y/N): ";
|
||||
if(strtolower($this->getInput("n")) === "y"){
|
||||
$config->set("enable-rcon", true);
|
||||
$password = substr(base64_encode(@Utils::getRandomBytes(20, false)), 3, 10);
|
||||
$password = substr(base64_encode(random_bytes(20)), 3, 10);
|
||||
$config->set("rcon.password", $password);
|
||||
echo "[*] " . $this->lang->rcon_password . ": " . $password . "\n";
|
||||
}else{
|
||||
|
Reference in New Issue
Block a user