From af9933676d69a650e1631ab279cf992c5f564280 Mon Sep 17 00:00:00 2001 From: mercury Date: Mon, 30 Sep 2024 17:12:11 +0400 Subject: [PATCH] karing import url --- app/bot.php | 26 +++++++++++++++++++++----- version | 2 ++ 2 files changed, 23 insertions(+), 5 deletions(-) diff --git a/app/bot.php b/app/bot.php index d481164..92982fc 100644 --- a/app/bot.php +++ b/app/bot.php @@ -4657,14 +4657,27 @@ DNS-over-HTTPS with IP: $text[] = "sing-box"; $text[] = "streisand"; $text[] = "hiddify"; + $text[] = "karing"; + + $si = "$scheme://{$domain}/pac/" . base64_encode(serialize([ + 'h' => $hash, + 't' => 'si', + 's' => $c['id'], + ])); + $xr = "$scheme://{$domain}/pac/" . base64_encode(serialize([ + 'h' => $hash, + 't' => 's', + 's' => $c['id'], + ])); + + $text[] = "\nxray config:
$xr
"; + $text[] = "sing-box config:
$si
"; - $text[] = "\nv2ray config:
$scheme://{$domain}/pac?h=$hash&t=s&s={$c['id']}
"; - $text[] = "sing-box config:
$scheme://{$domain}/pac?h=$hash&t=si&s={$c['id']}
"; $text[] = "sing-box windows: windows service"; $data[] = [ [ - 'text' => 'v2ray', + 'text' => 'xray', 'web_app' => ['url' => "https://{$domain}/pac?h=$hash&t=s&s={$c['id']}"], ], [ @@ -4826,6 +4839,9 @@ DNS-over-HTTPS with IP: case 'v': header("Location: v2rayng://install-config?url=$v2"); exit; + case 'k': + header("Location: karing://install-config?url=$si"); + exit; case 'h': header("Location: hiddify://install-config/?url=$si"); exit; @@ -5045,12 +5061,12 @@ DNS-over-HTTPS with IP: } $ruleset[] = [ "tag" => $r['name'], - "url" => "$scheme://{$domain}/pac?" . http_build_query([ + "url" => "$scheme://{$domain}/pac/" . base64_encode(serialize([ 'h' => $hash, 't' => 'si', 's' => $uid, 'r' => $r['name'], - ]), + ])), "update_interval" => $r['interval'], "type" => "remote", "format" => "binary", diff --git a/version b/version index 05ab0ab..1509876 100644 --- a/version +++ b/version @@ -1,3 +1,5 @@ +30.09.2024 v1.62 +- импорт профиля xray в karing 30.09.2024 v1.61.1 - фикс удаления ключа варпа через ноль 29.09.2024 v1.61