singbox for windows as service
This commit is contained in:
+10
-3
@@ -3764,7 +3764,7 @@ DNS-over-HTTPS with IP:
|
||||
);
|
||||
}
|
||||
|
||||
public function userXr($i, $fs = 0, $fv = 0)
|
||||
public function userXr($i, $fs = 0, $fv = 0, $a = 0)
|
||||
{
|
||||
$c = $this->getXray();
|
||||
$pac = $this->getPacConf() ?: $this->ip;
|
||||
@@ -3781,12 +3781,16 @@ DNS-over-HTTPS with IP:
|
||||
if (!empty($fv)) {
|
||||
return $fullv2ray;
|
||||
}
|
||||
if (!empty($a)) {
|
||||
return "$scheme://{$domain}/pac?h=$hash&t=si&s={$c['inbounds'][0]['settings']['clients'][$i]['id']}";
|
||||
}
|
||||
|
||||
$text[] = "Menu -> " . $this->i18n('xray') . " -> {$c['inbounds'][0]['settings']['clients'][$i]['email']}\n";
|
||||
$text[] = "<code>{$this->linkXray($i)}</code>\n";
|
||||
$text[] = "v2ray import: <a href='$v2ray'>v2rayng://install-config</a>";
|
||||
$text[] = "v2ray config: <code>$scheme://{$domain}/pac?h=$hash&t=s&s={$c['inbounds'][0]['settings']['clients'][$i]['id']}</code>\n";
|
||||
$text[] = "sing-box import: <a href='$sing'>sing-box://import-remote-profile</a>";
|
||||
$text[] = "sing-box import (Android, IOS): <a href='$sing'>sing-box://import-remote-profile</a>";
|
||||
$text[] = "sing-box windows: <a href='$scheme://{$domain}/pac?h=$hash&t=si&b=2&s={$c['inbounds'][0]['settings']['clients'][$i]['id']}'>windows service</a>";
|
||||
$text[] = "sing-box config: <code>$scheme://{$domain}/pac?h=$hash&t=si&s={$c['inbounds'][0]['settings']['clients'][$i]['id']}</code>";
|
||||
|
||||
$data[] = [
|
||||
@@ -3885,7 +3889,7 @@ DNS-over-HTTPS with IP:
|
||||
echo json_encode($c);
|
||||
}
|
||||
|
||||
public function singboxSubscription($key, $fs = 0)
|
||||
public function singboxSubscription($key, $fs = 0, $a = 0)
|
||||
{
|
||||
$pac = $this->getPacConf();
|
||||
$domain = $pac['domain'] ?: $this->ip;
|
||||
@@ -3897,6 +3901,9 @@ DNS-over-HTTPS with IP:
|
||||
if (!empty($fs)) {
|
||||
return $this->userXr($k, 1);
|
||||
}
|
||||
if (!empty($a)) {
|
||||
return $this->userXr($k, a: 1);
|
||||
}
|
||||
if (empty($v['off'])) {
|
||||
$flag = false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user