Compare commits

..

1 Commits

Author SHA1 Message Date
mercury 7bfebe8096 fix unset warp key 2024-09-30 09:58:48 +04:00
2 changed files with 13 additions and 7 deletions
+11 -7
View File
@@ -4513,10 +4513,14 @@ DNS-over-HTTPS with IP:
public function addWarpPlus($key)
{
$c = $this->getPacConf();
$c['warp'] = $key;
$c = $this->getPacConf();
if (!empty($key)) {
$c['warp'] = $key;
$this->send($this->input['chat'], 'Warp registration license: ' . $this->ssh("warp-cli --accept-tos registration license $key 2>&1", 'wp'));
} else {
unset($c['warp']);
}
$this->setPacConf($c);
$this->send($this->input['chat'], 'Warp registration license: ' . $this->ssh("warp-cli --accept-tos registration license $key", 'wp'));
sleep(1);
$this->warp();
}
@@ -4540,12 +4544,12 @@ DNS-over-HTTPS with IP:
} else {
$this->ssh('warp-svc > /dev/null 2>&1 &', 'wp');
sleep(3);
$this->ssh('warp-cli --accept-tos registration new', 'wp');
$this->send($this->input['chat'], 'Registration: ' . $this->ssh('warp-cli --accept-tos registration new 2>&1', 'wp'));
if (!empty($p['warp'])) {
$this->ssh("warp-cli --accept-tos registration license {$p['warp']}", 'wp');
$this->send($this->input['chat'], 'License: ' . $this->ssh("warp-cli --accept-tos registration license {$p['warp']} 2>&1", 'wp'));
}
$this->ssh('warp-cli --accept-tos mode proxy', 'wp');
$this->ssh('warp-cli --accept-tos connect', 'wp');
$this->send($this->input['chat'], 'Proxy mode: ' . $this->ssh('warp-cli --accept-tos mode proxy 2>&1', 'wp'));
$this->send($this->input['chat'], 'Connect: ' . $this->ssh('warp-cli --accept-tos connect 2>&1', 'wp'));
unset($p['warpoff']);
}
$this->setPacConf($p);
+2
View File
@@ -1,3 +1,5 @@
30.09.2024 v1.61.1
- фикс удаления ключа варпа через ноль
29.09.2024 v1.61
- включение/отключение процесса warp
29.09.2024 v1.60