mirror of
https://github.com/cedar2025/Xboard.git
synced 2025-01-22 18:48:14 -05:00
Compare commits
8 Commits
84f5a76577
...
5843006a52
Author | SHA1 | Date | |
---|---|---|---|
|
5843006a52 | ||
|
a60b23b17d | ||
|
6aee3ea40e | ||
|
d6b7ae6404 | ||
|
ddac216e2d | ||
|
42542725f7 | ||
|
ab34ef327a | ||
|
60ed240e66 |
@ -88,7 +88,8 @@ class ClashMeta
|
||||
return response($yaml, 200)
|
||||
->header('subscription-userinfo', "upload={$user['u']}; download={$user['d']}; total={$user['transfer_enable']}; expire={$user['expired_at']}")
|
||||
->header('profile-update-interval', '24')
|
||||
->header('content-disposition', 'attachment;filename*=UTF-8\'\'' . rawurlencode($appName));
|
||||
->header('content-disposition', 'attachment;filename*=UTF-8\'\'' . rawurlencode($appName))
|
||||
->header('profile-web-page-url', admin_setting('app_url'));
|
||||
}
|
||||
|
||||
/**
|
||||
@ -194,8 +195,6 @@ class ClashMeta
|
||||
$array['server'] = $server['host'];
|
||||
$array['port'] = $server['port'];
|
||||
$array['uuid'] = $password;
|
||||
$array['alterId'] = 0;
|
||||
$array['cipher'] = 'auto';
|
||||
$array['udp'] = true;
|
||||
|
||||
// XTLS流控算法
|
||||
@ -242,10 +241,8 @@ class ClashMeta
|
||||
$array['ws-opts']['path'] = $wsSettings['path'];
|
||||
if (isset($wsSettings['headers']['Host']) && !empty($wsSettings['headers']['Host']))
|
||||
$array['ws-opts']['headers'] = ['Host' => $wsSettings['headers']['Host']];
|
||||
if (isset($wsSettings['path']) && !empty($wsSettings['path']))
|
||||
$array['ws-path'] = $wsSettings['path'];
|
||||
if (isset($wsSettings['headers']['Host']) && !empty($wsSettings['headers']['Host']))
|
||||
$array['ws-headers'] = ['Host' => $wsSettings['headers']['Host']];
|
||||
$array['ws-opts']['max-early-data'] = 2560;
|
||||
$array['ws-opts']['early-data-header-name'] = 'Sec-WebSocket-Protocol';
|
||||
}
|
||||
}
|
||||
if ($server['network'] === 'grpc') {
|
||||
|
@ -190,7 +190,7 @@ class Shadowrocket
|
||||
if ($server['network_settings']) {
|
||||
$wsSettings = $server['network_settings'];
|
||||
if (isset($wsSettings['path']) && !empty($wsSettings['path']))
|
||||
$config['path'] = $wsSettings['path'];
|
||||
$config['path'] = $wsSettings['path'] . '?ed=2560';
|
||||
if (isset($wsSettings['headers']['Host']) && !empty($wsSettings['headers']['Host']))
|
||||
$config['obfsParam'] = $wsSettings['headers']['Host'];
|
||||
}
|
||||
|
@ -149,7 +149,7 @@ class SingBox
|
||||
$array['transport']['path'] = $wsSettings['path'];
|
||||
if (isset($wsSettings['headers']['Host']) && !empty($wsSettings['headers']['Host']))
|
||||
$array['transport']['headers'] = ['Host' => array($wsSettings['headers']['Host'])];
|
||||
$array['transport']['max_early_data'] = 2048;
|
||||
$array['transport']['max_early_data'] = 2560;
|
||||
$array['transport']['early_data_header_name'] = 'Sec-WebSocket-Protocol';
|
||||
}
|
||||
}
|
||||
@ -217,7 +217,7 @@ class SingBox
|
||||
$array['transport']['path'] = $wsSettings['path'];
|
||||
if (isset($wsSettings['headers']['Host']) && !empty($wsSettings['headers']['Host']))
|
||||
$array['transport']['headers'] = ['Host' => array($wsSettings['headers']['Host'])];
|
||||
$array['transport']['max_early_data'] = 2048;
|
||||
$array['transport']['max_early_data'] = 2560;
|
||||
$array['transport']['early_data_header_name'] = 'Sec-WebSocket-Protocol';
|
||||
}
|
||||
}
|
||||
@ -272,7 +272,7 @@ class SingBox
|
||||
if (isset($server['network_settings']['headers']['Host'])) {
|
||||
$array['transport']['headers'] = ['Host' => array($server['network_settings']['headers']['Host'])];
|
||||
}
|
||||
$array['transport']['max_early_data'] = 2048;
|
||||
$array['transport']['max_early_data'] = 2560;
|
||||
$array['transport']['early_data_header_name'] = 'Sec-WebSocket-Protocol';
|
||||
}
|
||||
}
|
||||
|
@ -49,8 +49,10 @@
|
||||
"auto_route": true,
|
||||
"domain_strategy": "prefer_ipv4",
|
||||
"endpoint_independent_nat": true,
|
||||
"inet4_address": "172.19.0.1/30",
|
||||
"inet6_address": "2001:0470:f9da:fdfa::1/64",
|
||||
"address": [
|
||||
"172.19.0.1/30",
|
||||
"2001:0470:f9da:fdfa::1/64"
|
||||
],
|
||||
"mtu": 9000,
|
||||
"sniff": true,
|
||||
"sniff_override_destination": true,
|
||||
|
Loading…
Reference in New Issue
Block a user