dsh-mobile-plugin 0.5.141 → 0.5.142
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/config/agent-presets/standard/skills/dsh-mobile-kb/SKILL.md +3 -1
- package/config/agent-presets/standard/skills/dsh-mobile-kb/references/cloudflare.md +30 -3
- package/config/agent-presets/standard/skills/dsh-mobile-kb/references/port-conflict.md +4 -3
- package/config/agent-presets/standard/skills/dsh-mobile-kb/references/tailscale.md +40 -0
- package/docs/extension-authoring.md +52 -0
- package/docs/extension-sample/index.html +27 -0
- package/docs/extension-sample/manifest.json +11 -2
- package/lib/cloudflared/provision.cjs +6 -1
- package/lib/cloudflared-named/api.cjs +132 -0
- package/lib/cloudflared-named/provision.cjs +205 -0
- package/lib/cloudflared-named/runner.cjs +252 -0
- package/lib/cloudflared-named/wiring.cjs +155 -0
- package/lib/frpc/provision.cjs +6 -1
- package/lib/impl.js +34 -5
- package/lib/mobile/permissions.js +1 -1
- package/lib/mobile/sync-inbox-store.js +8 -8
- package/lib/mobile/sync.js +14 -19
- package/lib/panel/index.html +17 -17
- package/lib/relay/config-store.js +4 -0
- package/lib/relay/control.js +5 -1
- package/lib/relay/core.js +7 -0
- package/lib/relay/ingress-verdict-store.cjs +68 -0
- package/lib/relay/loopback-auto-wiring.cjs +36 -0
- package/lib/relay/loopback-auto.cjs +80 -0
- package/lib/relay/pairing-payload.cjs +5 -1
- package/lib/remote/host.cjs +20 -1
- package/lib/remote/runtime.cjs +8 -0
- package/lib/remote/transport.cjs +7 -1
- package/lib/routes/control-plane.js +89 -4
- package/lib/routes/mobile-api.js +2 -2
- package/package.json +14 -13
|
@@ -94,6 +94,10 @@ const RemoteControlSettingsSchema = z.object({
|
|
|
94
94
|
// `cloudflared/wiring.cjs` 在 runner 报地址时 `settings.update` 落进来,手机端配置口
|
|
95
95
|
// (`relay-control.js` 的 configView / configPatch)**不开放**这一格,只能由运行时写。
|
|
96
96
|
cloudflareUrl: z.string().max(200).default(''),
|
|
97
|
+
// Cloudflare 命名隧道的公网地址(运行时写入,手机配置口不开放,同 cloudflareUrl 口径)。
|
|
98
|
+
// token / account / zone / hostname 等凭据只在本机 0600 文件(cloudflared-named/credentials.json),
|
|
99
|
+
// 绝不进这份对外投影。
|
|
100
|
+
cloudflareNamedUrl: z.string().max(300).default(''),
|
|
97
101
|
// 通用线路引擎:第三方线路清单(运行时写入,手机配置口不开放,见 core.js 默认状态)。
|
|
98
102
|
customRoutes: z.array(z.object({
|
|
99
103
|
url: z.string().max(300),
|
package/lib/relay/control.js
CHANGED
|
@@ -104,7 +104,11 @@ function controlAddresses(state, port, connectedRelay = '', options = {}) {
|
|
|
104
104
|
// (`state.cloudflareUrl` 非空)时才 push —— 空值没有可拨的地址,塞进来只会让总控白存一条。
|
|
105
105
|
// 它不并进 `direct` / `lan`:用户手填的直连地址原样保留,两条线路互不覆盖。
|
|
106
106
|
const cfUrl = typeof state.cloudflareUrl === 'string' ? state.cloudflareUrl.trim() : '';
|
|
107
|
-
|
|
107
|
+
// Cloudflare 命名隧道:同一条 kind:'cf' 线路,优先于快速隧道。两者都拿到地址时只报命名隧道那条
|
|
108
|
+
// ——它固定、在用户自己账号下;快速隧道那格留着当兜底,但不在同一时刻重复上报两条 cf。
|
|
109
|
+
const namedUrl = typeof state.cloudflareNamedUrl === 'string' ? state.cloudflareNamedUrl.trim() : '';
|
|
110
|
+
const effectiveCf = namedUrl || cfUrl;
|
|
111
|
+
if (effectiveCf) out.push({ kind: 'cf', url: effectiveCf });
|
|
108
112
|
// TCP 直连:用户填的 `host:port`(可能带方括号 IPv6)。不受 `lanEnabled` 管——它是一条独立的
|
|
109
113
|
// 裸 TCP 出站通道,关掉局域网直连时它照样能用;而它恰恰是「没配中转」那种配置下手机
|
|
110
114
|
// 唯一还能连上的地址,必须进总控这份兜底清单。
|
package/lib/relay/core.js
CHANGED
|
@@ -64,6 +64,9 @@ function defaultState() {
|
|
|
64
64
|
// 专属回环入口端口(默认 0 = 还没分配):worker 启动时绑定、宿主写回,手机配置口不开放。
|
|
65
65
|
// 局域网默认 51887 与 0.0.0.0 绑定都不动,它是另外一条只听 127.0.0.1 的入口。
|
|
66
66
|
tunnelIngressPort: 0,
|
|
67
|
+
// 回环入口判据的落盘副本:自检/自动体检记下的结论连原因与时间戳一起存,重启后短时恢复。
|
|
68
|
+
// 纯运行时字段,手机配置口不开放;老状态文件没这一格时按「没证据」处理。
|
|
69
|
+
loopbackVerdict: { state: '', reason: '', at: 0 },
|
|
67
70
|
// 自带 Cloudflare 兜底期间暂时收起的手填直连地址;兜底一停原样还原,绝不静默吞掉。
|
|
68
71
|
cloudflareFallbackBackup: { manualLanUrl: '', manualIpv6Url: '', manualIpv4Url: '', manualTcpUrl: '' },
|
|
69
72
|
// 是否把本机的网络地址加密上报给「总控」(地址目录)。默认开:这正是本功能一直以来的
|
|
@@ -83,6 +86,10 @@ function defaultState() {
|
|
|
83
86
|
// (`relay-control.js` 的 configView / configPatch 都不带它)。它是独立线路,上报时
|
|
84
87
|
// 走自己的 `kind:'cf'`,**不并进** manualLanUrl(用户手填的直连原样保留)。
|
|
85
88
|
cloudflareUrl: '',
|
|
89
|
+
// Cloudflare 命名隧道(用户自己账号)此刻拿到的固定公网地址(空 = 没配 / 没连上)。**纯运行时字段**:
|
|
90
|
+
// 由 `cloudflared-named/wiring.cjs` 在连上边缘时写入,手机配置口不开放。作为独立线路上报,
|
|
91
|
+
// 与快速隧道的 cloudflareUrl 并列;两者都非空时总控/二维码只取命名隧道这一条(见 control/pairing)。
|
|
92
|
+
cloudflareNamedUrl: '',
|
|
86
93
|
// 用户手填的 IPv6 直连地址(空 = 没填)。与上一条同一条口径:schema 里的一项、不进
|
|
87
94
|
// sidecar 配置,只影响「报给手机的 IPv6 候选」与二维码。
|
|
88
95
|
manualIpv6Url: '',
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
// 2026-11-29:回环判据落盘的纯函数:新鲜度与形状校验,落盘由装配层做。
|
|
2
|
+
// 2026-11-29:只认 ok / blocked;未知状态与陈旧证据都不回填,免得把旧判据当现状。
|
|
3
|
+
'use strict';
|
|
4
|
+
|
|
5
|
+
/** 运行时落盘字段:手机配置口不开放,只在装配层写回 relay.json 的 state。 */
|
|
6
|
+
const FIELD = 'loopbackVerdict';
|
|
7
|
+
/** 超过这个年龄的判据不再当现状,重启后按它决定要不要回填。 */
|
|
8
|
+
const FRESH_MS = 10 * 60 * 1000;
|
|
9
|
+
|
|
10
|
+
function isPlainObject(value) {
|
|
11
|
+
return value !== null && typeof value === 'object' && !Array.isArray(value);
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
/** 空判据每次都新建,调用方就地改了也不污染下一次。 */
|
|
15
|
+
function emptyVerdict() {
|
|
16
|
+
return { state: '', reason: '', at: 0 };
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* 只收形状合规的 ok / blocked 判据。
|
|
21
|
+
* reason 不是字符串就归空,at 不是正整数就归 0 —— 宁可丢细节,也不把坏值带进落盘字段。
|
|
22
|
+
*/
|
|
23
|
+
function normalize(raw) {
|
|
24
|
+
if (!isPlainObject(raw)) return null;
|
|
25
|
+
if (raw.state !== 'ok' && raw.state !== 'blocked') return null;
|
|
26
|
+
return {
|
|
27
|
+
state: raw.state,
|
|
28
|
+
reason: typeof raw.reason === 'string' ? raw.reason : '',
|
|
29
|
+
at: Number.isInteger(raw.at) && raw.at > 0 ? raw.at : 0,
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
/** 十分钟为界:正好 FRESH_MS 算新鲜,多一毫秒就算陈旧。 */
|
|
34
|
+
function fresh(verdict, now) {
|
|
35
|
+
if (!verdict || (verdict.state !== 'ok' && verdict.state !== 'blocked')) return false;
|
|
36
|
+
if (!(verdict.at > 0)) return false;
|
|
37
|
+
if (!Number.isFinite(now) || now < verdict.at) return false;
|
|
38
|
+
return now - verdict.at <= FRESH_MS;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
/** 落盘补丁只带这一个运行时字段;没有可用判据就写空形状,不写 null。 */
|
|
42
|
+
function patchOf(snapshot) {
|
|
43
|
+
return { [FIELD]: normalize(snapshot) || emptyVerdict() };
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* 重启恢复:新鲜则回填判据,陈旧 / 缺失 / 形状坏了都清掉。
|
|
48
|
+
* note 是可选的,装配层没带它时只返回结果,不因此抛错。
|
|
49
|
+
*/
|
|
50
|
+
function restore(state, note, now) {
|
|
51
|
+
const verdict = normalize(state && state[FIELD]);
|
|
52
|
+
if (verdict && fresh(verdict, now)) {
|
|
53
|
+
if (typeof note === 'function') note(verdict);
|
|
54
|
+
return verdict;
|
|
55
|
+
}
|
|
56
|
+
if (typeof note === 'function') note(null);
|
|
57
|
+
return null;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
module.exports = {
|
|
61
|
+
FIELD,
|
|
62
|
+
FRESH_MS,
|
|
63
|
+
normalize,
|
|
64
|
+
fresh,
|
|
65
|
+
patchOf,
|
|
66
|
+
restore,
|
|
67
|
+
get EMPTY() { return emptyVerdict(); },
|
|
68
|
+
};
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
// 2026-11-29:把回环判据的落盘、开机恢复与自动体检接到装配层交进来的依赖上。
|
|
2
|
+
// 这里只做接线:形状/新鲜度在 ingress-verdict-store,探测时机在 loopback-auto。
|
|
3
|
+
'use strict';
|
|
4
|
+
|
|
5
|
+
const verdictStore = require('./ingress-verdict-store.cjs');
|
|
6
|
+
const { createAutoLoopbackProbe } = require('./loopback-auto.cjs');
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* 组装一份「判据记账 + 自动体检」。
|
|
10
|
+
*
|
|
11
|
+
* - 开机先用落盘判据回填 ingress-guard:新鲜才信,陈旧/缺失当没证据。
|
|
12
|
+
* - note 是所有判据入口(自检、面板回环探针、自动体检)共用的记账:记进 guard,
|
|
13
|
+
* 结论(状态或原因)变了才写回 relay.json;at 每次探测都会刷新,不跟着反复写盘。
|
|
14
|
+
* - 探测与复查时机的调度全交给 loopback-auto,apply 由控制面的同一份 applier 注入,
|
|
15
|
+
* 保证「记判据 → 算信号 → 判据变了让线路重报」只走一条路。
|
|
16
|
+
*/
|
|
17
|
+
function createLoopbackAutoWiring({ state, core, guard, status, warn, probe, apply,
|
|
18
|
+
intervalMs, setTimer, clearTimer }) {
|
|
19
|
+
verdictStore.restore(state, guard.noteLoopback, Date.now());
|
|
20
|
+
|
|
21
|
+
const note = verdict => {
|
|
22
|
+
guard.noteLoopback(verdict);
|
|
23
|
+
const snap = guard.snapshot();
|
|
24
|
+
const saved = state.loopbackVerdict || {};
|
|
25
|
+
if (saved.state !== snap.state || saved.reason !== snap.reason) {
|
|
26
|
+
Object.assign(state, verdictStore.patchOf(snap));
|
|
27
|
+
core.saveState(state);
|
|
28
|
+
}
|
|
29
|
+
return snap;
|
|
30
|
+
};
|
|
31
|
+
|
|
32
|
+
const auto = createAutoLoopbackProbe({ probe, apply, status, warn, intervalMs, setTimer, clearTimer });
|
|
33
|
+
return { note, start: auto.start, stop: auto.stop, onLan: auto.onLan };
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
module.exports = { createLoopbackAutoWiring };
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
// 2026-11-29:开机/局域网就绪后的轻量回环自动体检调度,探测与落盘都由注入完成。
|
|
2
|
+
// 只决定「什么时候探」:不 require、不读写文件,端口与隧道一概不碰。
|
|
3
|
+
// 探测失败就是没证据:unknown、空结果、异常一律清掉旧判据,不凭一次超时判端口被占。
|
|
4
|
+
'use strict';
|
|
5
|
+
|
|
6
|
+
function createAutoLoopbackProbe({
|
|
7
|
+
probe,
|
|
8
|
+
apply,
|
|
9
|
+
status,
|
|
10
|
+
warn = () => {},
|
|
11
|
+
intervalMs = 30000,
|
|
12
|
+
setTimer = (fn, ms) => setTimeout(fn, ms),
|
|
13
|
+
clearTimer = (handle) => clearTimeout(handle),
|
|
14
|
+
}) {
|
|
15
|
+
let started = false;
|
|
16
|
+
let inFlight = false;
|
|
17
|
+
let timer = null;
|
|
18
|
+
let lanKey = null;
|
|
19
|
+
|
|
20
|
+
function schedule() {
|
|
21
|
+
timer = setTimer(() => {
|
|
22
|
+
if (!started) return; // stop 之后不再排下一次
|
|
23
|
+
tick();
|
|
24
|
+
schedule();
|
|
25
|
+
}, intervalMs);
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
async function tick() {
|
|
29
|
+
if (!started) return;
|
|
30
|
+
const snapshot = status() || {};
|
|
31
|
+
const lan = snapshot.lan || {};
|
|
32
|
+
if (lan.state !== 'listening') return;
|
|
33
|
+
const port = lan.port;
|
|
34
|
+
// 端口只从快照读,绝不在这里改写或保存。
|
|
35
|
+
if (!Number.isInteger(port) || port < 1024 || port > 65535) return;
|
|
36
|
+
if (inFlight) return;
|
|
37
|
+
inFlight = true;
|
|
38
|
+
try {
|
|
39
|
+
let verdict;
|
|
40
|
+
try {
|
|
41
|
+
verdict = await probe(port);
|
|
42
|
+
} catch (err) {
|
|
43
|
+
warn(`回环自动探测异常:${err && err.message ? err.message : String(err)}`);
|
|
44
|
+
apply(null);
|
|
45
|
+
return;
|
|
46
|
+
}
|
|
47
|
+
// 只有明确的 ok / blocked 算证据,其余(含 unknown / null)清掉旧证据。
|
|
48
|
+
apply(verdict && (verdict.state === 'ok' || verdict.state === 'blocked') ? verdict : null);
|
|
49
|
+
} finally {
|
|
50
|
+
inFlight = false;
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
function start() {
|
|
55
|
+
if (started) return; // 幂等:不重复起定时器
|
|
56
|
+
started = true;
|
|
57
|
+
tick();
|
|
58
|
+
schedule();
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
function stop() {
|
|
62
|
+
started = false; // 幂等
|
|
63
|
+
if (timer !== null) {
|
|
64
|
+
clearTimer(timer);
|
|
65
|
+
timer = null;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
function onLan(lan) {
|
|
70
|
+
if (!started) return;
|
|
71
|
+
const key = (lan && lan.state) + ':' + (lan && lan.port);
|
|
72
|
+
if (key === lanKey) return; // 首次键为 null,所以首次 onLan 一定放行一次
|
|
73
|
+
lanKey = key;
|
|
74
|
+
tick();
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
return { start, stop, onLan };
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
module.exports = { createAutoLoopbackProbe };
|
|
@@ -74,7 +74,11 @@ function pairingRoutes(state, taken) {
|
|
|
74
74
|
};
|
|
75
75
|
for (const row of providerLinesOf(state)) push(row);
|
|
76
76
|
// Cloudflare 兜底隧道:一个 https 地址,独立一格。带进码里,只有 Cloudflare 也能在外配对。
|
|
77
|
-
|
|
77
|
+
// 命名隧道优先:固定域名、在用户自己账号下;快速隧道那格留着当兜底,不同时进码。
|
|
78
|
+
const cfRaw = typeof state.cloudflareNamedUrl === 'string' && state.cloudflareNamedUrl.trim()
|
|
79
|
+
? state.cloudflareNamedUrl
|
|
80
|
+
: state.cloudflareUrl;
|
|
81
|
+
const cf = typeof cfRaw === 'string' ? cfRaw.trim().replace(/\/+$/, '') : '';
|
|
78
82
|
if (cf) push({ url: cf, name: 'Cloudflare', transport: 'http' });
|
|
79
83
|
return out.slice(0, QR_ROUTES_MAX);
|
|
80
84
|
}
|
package/lib/remote/host.cjs
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
// 显式一次性邀请授权远程电脑,并把认证后的加密流接到本机固定网页入口。
|
|
2
|
+
// 2026-11-29:配对回包的密文里附带总控订阅凭据,供本机零安装的启动器查线路;明文邀请不含此凭据。
|
|
2
3
|
// 浏览器这条跨源客户端认不了头也认不了预检头,故两条入口同时认 instance 查询参数。
|
|
3
4
|
'use strict';
|
|
4
5
|
|
|
@@ -32,7 +33,7 @@ function parseHandshake(data, binary) {
|
|
|
32
33
|
}
|
|
33
34
|
|
|
34
35
|
|
|
35
|
-
function createRemoteHost({ state, credentials, routesOf, getUpstreamPort, getWebPort, getLaunchToken, getConnectionInfo, onControl, onInvite, now = Date.now, log = () => {} }) {
|
|
36
|
+
function createRemoteHost({ state, credentials, routesOf, getUpstreamPort, getWebPort, getLaunchToken, getConnectionInfo, getDirectoryCredentials, onControl, onInvite, now = Date.now, log = () => {} }) {
|
|
36
37
|
const tickets = new Map();
|
|
37
38
|
const sessions = new Set();
|
|
38
39
|
const throttle = createPairThrottle({ now });
|
|
@@ -42,6 +43,22 @@ function createRemoteHost({ state, credentials, routesOf, getUpstreamPort, getWe
|
|
|
42
43
|
const name = () => String(state.name || state.instanceName || 'DSH');
|
|
43
44
|
const info = async () => getConnectionInfo ? await getConnectionInfo() : undefined;
|
|
44
45
|
const routes = async () => (typeof routesOf === 'function' ? await routesOf() : []).map(({ url, channel }) => ({ url, channel }));
|
|
46
|
+
// 总控订阅凭据只放进配对回包的密文:邀请串是明文、可转发,绝不能带。取不到就整格不下发,
|
|
47
|
+
// 启动器退回邀请里的线路快照,不能因为总控没配好就让配对失败。
|
|
48
|
+
const directory = async () => {
|
|
49
|
+
if (typeof getDirectoryCredentials !== 'function') return undefined;
|
|
50
|
+
try {
|
|
51
|
+
const value = await getDirectoryCredentials();
|
|
52
|
+
if (!value || typeof value !== 'object') return undefined;
|
|
53
|
+
const text = (input, max) => typeof input === 'string' && input.length > 0 && input.length <= max ? input.trim() : '';
|
|
54
|
+
const result = {
|
|
55
|
+
baseUrl: text(value.baseUrl, 512),
|
|
56
|
+
token: text(value.token, 512),
|
|
57
|
+
historyKey: text(value.historyKey, 512),
|
|
58
|
+
};
|
|
59
|
+
return result.baseUrl && result.token && result.historyKey ? result : undefined;
|
|
60
|
+
} catch { return undefined; }
|
|
61
|
+
};
|
|
45
62
|
const pairAad = (ticketId, direction) => JSON.stringify(['dsh-computer-pair-v1', instanceId(), ticketId, direction]);
|
|
46
63
|
|
|
47
64
|
function valid(record) {
|
|
@@ -130,6 +147,8 @@ function createRemoteHost({ state, credentials, routesOf, getUpstreamPort, getWe
|
|
|
130
147
|
const device = { deviceId: request.deviceId, name: String(request.name || 'Computer').slice(0, 128), platform: 'computer' };
|
|
131
148
|
const issued = credentials.issue(instanceId(), device, '', undefined, { deviceKey: request.deviceKey, keyId: request.keyId, permissions: [], remoteWeb: true });
|
|
132
149
|
const binding = { instanceId: instanceId(), name: name(), deviceId: issued.deviceId, credential: issued.credential, keyId: request.keyId, routes: await routes(), createdAt: now(), nonce: request.nonce, connectionInfo: await info() };
|
|
150
|
+
const directoryCredentials = await directory();
|
|
151
|
+
if (directoryCredentials) binding.directory = directoryCredentials;
|
|
133
152
|
throttle.noteSuccess();
|
|
134
153
|
sendJson(res, 200, { ok: true, v: 1, sealed: c.sealJson(keys.down, binding, pairAad(ticket.ticketId, 'down')) });
|
|
135
154
|
} catch (error) {
|
package/lib/remote/runtime.cjs
CHANGED
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
// 2026-11-26:远程电脑取启动令牌改走 launchTokenOf,跟新宿主删 browserAuth 后的兜底同源,别再硬读旧字段。
|
|
4
4
|
// 电脑间远程网页的装配与生命周期;入口只在可信本机界面签发。
|
|
5
5
|
// 落点代理转给宿主 web 服务时跟随宿主实际绑定地址(见 relay/tunnel-forwarder.cjs)。
|
|
6
|
+
// 2026-11-29:装配层把总控地址/令牌/历史密钥作为取值器交给配对回包;只在配对时读一次。
|
|
7
|
+
const { CONTROL_BASE_URL } = require('../relay/control.js')
|
|
8
|
+
const core = require('../relay/core.js')
|
|
6
9
|
const os = require('node:os');
|
|
7
10
|
const { launchTokenOf } = require('../mobile/host-web.js');
|
|
8
11
|
const { createRemoteStore } = require('./store.cjs');
|
|
@@ -27,6 +30,11 @@ function mountRemoteComputers({ ctx, state, credentials, registerRoute, lanPortI
|
|
|
27
30
|
getWebPort: () => ctx.webServer.port,
|
|
28
31
|
getLaunchToken: () => launchTokenOf(ctx) || '',
|
|
29
32
|
getConnectionInfo: control.connectionInfo,
|
|
33
|
+
getDirectoryCredentials: () => ({
|
|
34
|
+
baseUrl: CONTROL_BASE_URL,
|
|
35
|
+
token: state.controlToken || '',
|
|
36
|
+
historyKey: core.ensureHistoryKey(state),
|
|
37
|
+
}),
|
|
30
38
|
onControl: control.onControl, onInvite, log,
|
|
31
39
|
});
|
|
32
40
|
const { createRemoteTunnels } = require('./tunnels.cjs');
|
package/lib/remote/transport.cjs
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
// 远程加密传输保留真实 HTTP 代理与非协议页面证据,网络诊断不泄露响应内容。
|
|
2
2
|
// 握手超时按「有没有进展」判:升级阶段给一个上限,升级后每收到一条消息就重置沉默窗口,
|
|
3
3
|
// 慢网只要还在往前推就一直等,只有彻底没声音的线路才会被判死。
|
|
4
|
+
// 2026-11-29:配对回包里的总控订阅凭据(baseUrl/token/historyKey)原样带出,供本机零安装的启动器查线路。
|
|
4
5
|
'use strict';
|
|
5
6
|
|
|
6
7
|
const http = require('node:http');
|
|
@@ -115,7 +116,12 @@ async function pairComputer(textOrObject, options = {}) {
|
|
|
115
116
|
const binding = c.openJson(keys.down, response.sealed, aad('down'));
|
|
116
117
|
if (binding.instanceId !== invite.instanceId || binding.deviceId !== deviceId || binding.keyId !== keyId || binding.nonce !== nonce || typeof binding.credential !== 'string' || !binding.credential || !Array.isArray(binding.routes)) throw c.error('REMOTE_AUTH', 'Unexpected computer identity');
|
|
117
118
|
for (const candidate of binding.routes) c.endpoint(candidate, TUNNEL_PATH, true);
|
|
118
|
-
|
|
119
|
+
const directory = binding.directory && typeof binding.directory === 'object'
|
|
120
|
+
? { baseUrl: binding.directory.baseUrl, token: binding.directory.token, historyKey: binding.directory.historyKey }
|
|
121
|
+
: null;
|
|
122
|
+
const usableDirectory = directory && [directory.baseUrl, directory.token, directory.historyKey]
|
|
123
|
+
.every((value) => typeof value === 'string' && value.length > 0 && value.length <= 512) ? directory : null;
|
|
124
|
+
return { instanceId: binding.instanceId, name: binding.name, deviceId, credential: binding.credential, deviceKey, keyId, routes: binding.routes, createdAt: binding.createdAt, ...(binding.connectionInfo ? { connectionInfo: binding.connectionInfo } : {}), ...(usableDirectory ? { directory: usableDirectory } : {}) };
|
|
119
125
|
} catch (err) {
|
|
120
126
|
const next = err.code?.startsWith('REMOTE_') ? err : c.error('REMOTE_AUTH', 'Computer pairing authentication failed');
|
|
121
127
|
const evidence = error => ['REMOTE_PROXY', 'REMOTE_PROXY_CONFIGURED', 'REMOTE_INTERCEPTED'].includes(error?.code);
|
|
@@ -109,6 +109,23 @@ const LOOPBACK_PROBE_TIMEOUT_MS = 1500;
|
|
|
109
109
|
* 必然失败 —— 那会让「TCP 直连」这颗检测永远报不通,地址完全正确也一样。
|
|
110
110
|
*/
|
|
111
111
|
function probeTcpHealth(host, port, timeoutMs) {
|
|
112
|
+
return probeTcpResponse(host, port, timeoutMs).then(result => result.answered ? result.body : null);
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
/**
|
|
116
|
+
* 与 probeTcpHealth 同一条裸 TCP 请求,但把「没人答」和「答的不是 JSON」分开。
|
|
117
|
+
*
|
|
118
|
+
* 回环自动体检每 30 秒无人值守地跑:一次超时只是没证据,绝不能判成端口被抢、
|
|
119
|
+
* 触发落点重连和云端改写;只有真收到别人的应答才算被抢。面板手动探针同用这一份。
|
|
120
|
+
*/
|
|
121
|
+
async function probeLoopbackVerdict(port, timeoutMs = LOOPBACK_PROBE_TIMEOUT_MS) {
|
|
122
|
+
const result = await probeTcpResponse('127.0.0.1', port, timeoutMs);
|
|
123
|
+
if (!result.answered) return { state: 'unknown', reason: '回环 health 没回应,无法判断端口是否被抢占' };
|
|
124
|
+
return loopbackVerdictOf(result.body);
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
/** 裸 TCP health 探针的底层:answered 说明收到过应答(哪怕解析失败),body 是解析出的 JSON 或 null。 */
|
|
128
|
+
function probeTcpResponse(host, port, timeoutMs) {
|
|
112
129
|
return new Promise((resolve) => {
|
|
113
130
|
let settled = false;
|
|
114
131
|
const chunks = [];
|
|
@@ -119,10 +136,11 @@ function probeTcpHealth(host, port, timeoutMs) {
|
|
|
119
136
|
socket.write('GET /api/mobile/v1/health HTTP/1.1\r\nHost: probe\r\nAccept: application/json\r\nConnection: close\r\n\r\n');
|
|
120
137
|
});
|
|
121
138
|
socket.on('data', (chunk) => { chunks.push(chunk); });
|
|
122
|
-
socket.once('timeout', () => finish(null));
|
|
123
|
-
socket.once('error', () => finish(null));
|
|
139
|
+
socket.once('timeout', () => finish({ answered: false, body: null }));
|
|
140
|
+
socket.once('error', () => finish({ answered: false, body: null }));
|
|
124
141
|
socket.once('close', () => {
|
|
125
|
-
try { finish(JSON.parse(probeBodyOf(Buffer.concat(chunks)))
|
|
142
|
+
try { finish({ answered: true, body: JSON.parse(probeBodyOf(Buffer.concat(chunks))) }); }
|
|
143
|
+
catch { finish({ answered: true, body: null }); }
|
|
126
144
|
});
|
|
127
145
|
});
|
|
128
146
|
}
|
|
@@ -365,6 +383,9 @@ function registerControlPlaneRoutes(deps) {
|
|
|
365
383
|
// 自检把回环判据交给 ingress-guard;判定结果变了再让总控重报,缺省时只跑自检不改别的。
|
|
366
384
|
noteLoopbackVerdict = null,
|
|
367
385
|
onIngressVerdictChanged = null,
|
|
386
|
+
// 把「记判据 → 算信号 → 判据变了重报」这一份 applier 交给装配层,自动体检共用它,
|
|
387
|
+
// 避免两处各记一套、探测结果绕过了总控重报与线路重连。
|
|
388
|
+
onVerdictApplierReady = null,
|
|
368
389
|
} = deps;
|
|
369
390
|
/**
|
|
370
391
|
* 面板读的 status 在宿主那份上补一格总控上报目的地。包在这一层而不是
|
|
@@ -428,6 +449,7 @@ function registerControlPlaneRoutes(deps) {
|
|
|
428
449
|
try { onIngressVerdictChanged() } catch { /* 重报失败不拖垮本次回包 */ }
|
|
429
450
|
}
|
|
430
451
|
}
|
|
452
|
+
if (typeof onVerdictApplierReady === 'function') onVerdictApplierReady(applyLoopbackVerdict)
|
|
431
453
|
const localOnly = baseLocalOnly;
|
|
432
454
|
|
|
433
455
|
registerRoute({ kind: 'exact', path: '/api/relay/feedback', handler: localOnly(['GET', 'POST'], (req, res) =>
|
|
@@ -744,6 +766,7 @@ function registerControlPlaneRoutes(deps) {
|
|
|
744
766
|
fields.tailcat = take('tailcat', () => deps.tailcat && typeof deps.tailcat.status === 'function' ? deps.tailcat.status() : null)
|
|
745
767
|
fields.frp = take('frp', () => deps.frp && typeof deps.frp.status === 'function' ? deps.frp.status() : null)
|
|
746
768
|
fields.cloudflare = take('cloudflare', () => deps.cloudflare && typeof deps.cloudflare.status === 'function' ? deps.cloudflare.status() : null)
|
|
769
|
+
fields.cloudflareNamed = take('cloudflareNamed', () => deps.cloudflareNamed && typeof deps.cloudflareNamed.status === 'function' ? deps.cloudflareNamed.status() : null)
|
|
747
770
|
fields.zeroNews = take('zeroNews', () => deps.zeroNews && typeof deps.zeroNews.status === 'function' ? deps.zeroNews.status() : null)
|
|
748
771
|
fields.panelUrl = take('panelUrl', () => panelUrlOf(req), '')
|
|
749
772
|
fields.panelScope = take('panelScope', () => panelScopeOf(req), 'public')
|
|
@@ -866,6 +889,62 @@ function registerControlPlaneRoutes(deps) {
|
|
|
866
889
|
}
|
|
867
890
|
}) })
|
|
868
891
|
|
|
892
|
+
// ── Cloudflare 命名隧道(用户自己账号):配置 / 连接 / 断开 / 删除 ───────────────
|
|
893
|
+
// 两种模式:mode:'token' 用用户在自己后台建好的隧道(tunnelToken + hostname + localPort),
|
|
894
|
+
// mode:'api' 用 API Token 代建(apiToken + accountId + zoneId + hostname + localPort)。
|
|
895
|
+
// 所有 token 只在这次请求的 body 里经过,落本机 0600 凭据文件,绝不进 status / 日志 / 二维码。
|
|
896
|
+
const namedErr = (res, fallback, err) => sendJson(res, 500, {
|
|
897
|
+
ok: false,
|
|
898
|
+
error: {
|
|
899
|
+
code: (err && err.code && String(err.code).startsWith('CF_')) ? err.code : fallback,
|
|
900
|
+
message: err && err.message ? err.message : String(err),
|
|
901
|
+
},
|
|
902
|
+
})
|
|
903
|
+
registerRoute({ kind: 'exact', path: '/api/cloudflare/named/configure', handler: localOnly('POST', async (req, res) => {
|
|
904
|
+
if (!deps.cloudflareNamed || typeof deps.cloudflareNamed.configure !== 'function') {
|
|
905
|
+
return sendJson(res, 503, { ok: false, error: { code: 'cloudflare-named-unavailable', message: '这台宿主没有接入 Cloudflare 命名隧道能力' } })
|
|
906
|
+
}
|
|
907
|
+
let body = null
|
|
908
|
+
try { body = await readJson(req) } catch { body = null }
|
|
909
|
+
try {
|
|
910
|
+
const current = await deps.cloudflareNamed.configure(body || {})
|
|
911
|
+
sendJson(res, 200, { ok: true, ...(current || {}) })
|
|
912
|
+
} catch (err) { namedErr(res, 'cloudflare-named-configure-failed', err) }
|
|
913
|
+
}) })
|
|
914
|
+
registerRoute({ kind: 'exact', path: '/api/cloudflare/named/start', handler: localOnly('POST', async (_req, res) => {
|
|
915
|
+
if (!deps.cloudflareNamed || typeof deps.cloudflareNamed.start !== 'function') {
|
|
916
|
+
return sendJson(res, 503, { ok: false, error: { code: 'cloudflare-named-unavailable', message: '这台宿主没有接入 Cloudflare 命名隧道能力' } })
|
|
917
|
+
}
|
|
918
|
+
try {
|
|
919
|
+
const current = await deps.cloudflareNamed.start()
|
|
920
|
+
sendJson(res, 200, { ok: true, ...(current || {}) })
|
|
921
|
+
} catch (err) { namedErr(res, 'cloudflare-named-start-failed', err) }
|
|
922
|
+
}) })
|
|
923
|
+
registerRoute({ kind: 'exact', path: '/api/cloudflare/named/disconnect', handler: localOnly('POST', async (_req, res) => {
|
|
924
|
+
if (!deps.cloudflareNamed || typeof deps.cloudflareNamed.disconnect !== 'function') {
|
|
925
|
+
return sendJson(res, 503, { ok: false, error: { code: 'cloudflare-named-unavailable', message: '这台宿主没有接入 Cloudflare 命名隧道能力' } })
|
|
926
|
+
}
|
|
927
|
+
try {
|
|
928
|
+
const current = await deps.cloudflareNamed.disconnect()
|
|
929
|
+
sendJson(res, 200, { ok: true, ...(current || {}) })
|
|
930
|
+
} catch (err) { namedErr(res, 'cloudflare-named-disconnect-failed', err) }
|
|
931
|
+
}) })
|
|
932
|
+
// 删除隧道与 DNS 不可逆:body.confirm 必须是真值,面板要先弹二次确认再调。
|
|
933
|
+
registerRoute({ kind: 'exact', path: '/api/cloudflare/named/remove', handler: localOnly('POST', async (req, res) => {
|
|
934
|
+
if (!deps.cloudflareNamed || typeof deps.cloudflareNamed.remove !== 'function') {
|
|
935
|
+
return sendJson(res, 503, { ok: false, error: { code: 'cloudflare-named-unavailable', message: '这台宿主没有接入 Cloudflare 命名隧道能力' } })
|
|
936
|
+
}
|
|
937
|
+
let body = null
|
|
938
|
+
try { body = await readJson(req) } catch { body = null }
|
|
939
|
+
if (!body || body.confirm !== true) {
|
|
940
|
+
return sendJson(res, 400, { ok: false, error: { code: 'cloudflare-named-confirm-required', message: '删除会同时移除云端隧道与 DNS 记录,请确认' } })
|
|
941
|
+
}
|
|
942
|
+
try {
|
|
943
|
+
const current = await deps.cloudflareNamed.remove()
|
|
944
|
+
sendJson(res, 200, { ok: true, ...(current || {}) })
|
|
945
|
+
} catch (err) { namedErr(res, 'cloudflare-named-remove-failed', err) }
|
|
946
|
+
}) })
|
|
947
|
+
|
|
869
948
|
// ── ZeroNews 线路:面板「保存并连接 / 断开」——自动下载客户端、写 AuthToken、建隧道、拿域名 ──
|
|
870
949
|
// token 由用户在「快速开始」页复制后粘进面板(厂商现行 CLI 用 `authtoken`);body 里没带就退回
|
|
871
950
|
// 原有的浏览器登录那条路。token 只在这次请求里经过,不落盘、不记日志。
|
|
@@ -1465,7 +1544,7 @@ function registerControlPlaneRoutes(deps) {
|
|
|
1465
1544
|
}
|
|
1466
1545
|
let verdict
|
|
1467
1546
|
try {
|
|
1468
|
-
verdict =
|
|
1547
|
+
verdict = await probeLoopbackVerdict(port)
|
|
1469
1548
|
} catch {
|
|
1470
1549
|
verdict = { state: 'unknown', reason: '回环 health 探测失败,无法判断端口是否被抢占' }
|
|
1471
1550
|
}
|
|
@@ -1793,6 +1872,11 @@ const WEB_ACCESS_ROUTES = new Set([
|
|
|
1793
1872
|
// Cloudflare 兜底隧道的启停:与其它管理动作一样不按来源拦,仍留在清单里保持盘点完整。
|
|
1794
1873
|
'/api/cloudflare/start',
|
|
1795
1874
|
'/api/cloudflare/stop',
|
|
1875
|
+
// Cloudflare 命名隧道:本机管理动作(配置/连接/断开/删除),盘点清单与来源策略与其它管理动作一致。
|
|
1876
|
+
'/api/cloudflare/named/configure',
|
|
1877
|
+
'/api/cloudflare/named/start',
|
|
1878
|
+
'/api/cloudflare/named/disconnect',
|
|
1879
|
+
'/api/cloudflare/named/remove',
|
|
1796
1880
|
// ZeroNews 公网地址读取:localOnly 的本机只读路由,留在清单里保持盘点完整。
|
|
1797
1881
|
'/api/relay/zeronews/endpoints',
|
|
1798
1882
|
'/api/relay/zeronews/account',
|
|
@@ -1844,5 +1928,6 @@ module.exports = {
|
|
|
1844
1928
|
panelUrlOf,
|
|
1845
1929
|
panelScopeOf,
|
|
1846
1930
|
probeTcpHealth,
|
|
1931
|
+
probeLoopbackVerdict,
|
|
1847
1932
|
WEB_ACCESS_ROUTES,
|
|
1848
1933
|
};
|
package/lib/routes/mobile-api.js
CHANGED
|
@@ -478,11 +478,11 @@ function registerMobileRoutes(deps) {
|
|
|
478
478
|
}),
|
|
479
479
|
})
|
|
480
480
|
|
|
481
|
-
// 设备批量同步:申领一次性入场券 +
|
|
481
|
+
// 设备批量同步:申领一次性入场券 + 换机回执收发。三条端点、两条注册(ack 按 method
|
|
482
482
|
// 分派写 / 读,宿主 webServer 一个路径只能挂一个 handler),都走 route() 即包 guarded ——
|
|
483
483
|
// 只有已配对设备才能领券或碰收件箱,否则任何人能领走配对资格、往这台机器里塞东西。
|
|
484
484
|
route('/api/mobile/v1/sync/tickets', syncHandlers.handleMintTickets)
|
|
485
|
-
route('/api/mobile/v1/sync/
|
|
485
|
+
route('/api/mobile/v1/sync/ack', syncHandlers.handleAck)
|
|
486
486
|
// 局域网/中转连接信息。**这条由宿主自己回答**:中转只转发,不再代答。
|
|
487
487
|
// 纯局域网配对(App 只扫到局域网二维码、完全不经中转)需要一个宿主自己回答的地址,
|
|
488
488
|
// 否则 App 拿不到 lanCandidates,换网卡后就再也找不到这台机器;中转在中间时这条
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-mobile-plugin",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.142",
|
|
4
4
|
"description": "Mobile API (/api/mobile/v1) and relay client for the DSH mobile app — desktop profile build (dsh 0.2.x, peers resolved by the host)",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"icon": "./icon.png",
|
|
@@ -117,22 +117,23 @@
|
|
|
117
117
|
"yaml": "2.9.1"
|
|
118
118
|
},
|
|
119
119
|
"dshMobileReleaseNotes": {
|
|
120
|
-
"version": "0.5.
|
|
120
|
+
"version": "0.5.142",
|
|
121
121
|
"kinds": [
|
|
122
|
+
"feature",
|
|
122
123
|
"fix"
|
|
123
124
|
],
|
|
124
125
|
"notes": {
|
|
125
|
-
"zh-Hans": "-
|
|
126
|
-
"zh-Hant": "-
|
|
127
|
-
"en": "-
|
|
128
|
-
"ja": "-
|
|
129
|
-
"ko": "-
|
|
130
|
-
"de": "-
|
|
131
|
-
"es": "-
|
|
132
|
-
"fr": "-
|
|
133
|
-
"pt": "-
|
|
134
|
-
"ru": "-
|
|
135
|
-
"tr": "-
|
|
126
|
+
"zh-Hans": "- 新增 Cloudflare 命名隧道:用你自己的域名做固定入口,隧道建在你的 Cloudflare 账号下、可在后台随时管理。可以自己在后台建好后填隧道 token,也可以只填 API Token 让插件帮你建隧道、写 DNS。凭据只存在这台电脑上。\n- 修复换机时旧手机可能把这台电脑上的设备列表清空的问题:设备自动删除的广播不再生效,换机数据改用一次性回执收发。\n- 局域网就绪后会自动体检专属回环端口是否被占,不再因为一次探测超时就误判端口冲突。",
|
|
127
|
+
"zh-Hant": "- 新增 Cloudflare 命名隧道:用你自己的網域做固定入口,隧道建在你的 Cloudflare 帳號下、可在後台隨時管理。可以自己在後台建好後填隧道 token,也可以只填 API Token 讓外掛幫你建隧道、寫 DNS。憑證只存在這台電腦上。\n- 修復換機時舊手機可能把這台電腦上的裝置清單清空的問題:裝置自動刪除的廣播不再生效,換機資料改用一次性回執收發。\n- 區域網路就緒後會自動體檢專屬回環連接埠是否被佔,不再因為一次探測逾時就誤判連接埠衝突。",
|
|
128
|
+
"en": "- Added Cloudflare named tunnels: use your own domain as a fixed entry. The tunnel lives in your Cloudflare account and can be managed in the dashboard any time. Either set it up in the dashboard yourself and paste the tunnel token, or just provide an API Token and let the plugin create the tunnel and DNS for you. Credentials stay on this computer only.\n- Fixed an issue where, after switching phones, an old phone could clear the device list on this computer: automatic device-deletion broadcasts no longer take effect, and migration data now uses one-time receipts.\n- Once the LAN is ready, the dedicated loopback port is checked automatically, so a single timed-out probe no longer causes a false port-conflict warning.",
|
|
129
|
+
"ja": "- Cloudflare の名前付きトンネルを追加しました。自分のドメインを固定の入口として使え、トンネルは自分の Cloudflare アカウントに作られ、ダッシュボードでいつでも管理できます。ダッシュボードで自分で作ってトンネルトークンを貼る方法と、API Token だけを入力してプラグインにトンネルと DNS を作らせる方法があります。認証情報はこのコンピュータにだけ保存されます。\n- 機種変更時に古い端末がこのコンピュータの端末一覧を消してしまう問題を修正しました。端末の自動削除の通知は効かなくなり、移行データは一度きりの受領書でやり取りします。\n- ローカルネットワークが準備できると、専用のループバックポートを自動で診断し、一度の探測のタイムアウトだけでポート競合と誤判定することがなくなりました。",
|
|
130
|
+
"ko": "- Cloudflare 명명 터널을 추가했습니다. 자신의 도메인을 고정 진입점으로 사용하고, 터널은 자신의 Cloudflare 계정에 만들어 대시보드에서 언제든 관리할 수 있습니다. 대시보드에서 직접 만든 뒤 터널 토큰을 붙여넣거나, API Token만 입력해 플러그인이 터널과 DNS를 만들어 주게 할 수 있습니다. 인증 정보는 이 컴퓨터에만 저장됩니다.\n- 기기 변경 시 이전 휴대폰이 이 컴퓨터의 기기 목록을 지워버리던 문제를 수정했습니다. 기기 자동 삭제 알림은 더 이상 적용되지 않으며, 이전 데이터는 일회성 확인증으로 주고받습니다.\n- 로컬 네트워크가 준비되면 전용 루프백 포트를 자동으로 점검해, 한 번의 탐지 시간 초과만으로 포트 충돌로 오판하지 않습니다.",
|
|
131
|
+
"de": "- Neue Cloudflare Named Tunnels: Nutzen Sie Ihre eigene Domain als festen Zugang. Der Tunnel wird in Ihrem Cloudflare-Konto erstellt und kann jederzeit im Dashboard verwaltet werden. Richten Sie ihn entweder selbst im Dashboard ein und fügen Sie den Tunnel-Token ein, oder geben Sie nur einen API Token ein und lassen Sie das Plugin Tunnel und DNS für Sie anlegen. Zugangsdaten bleiben ausschließlich auf diesem Computer.\n- Behoben: Nach einem Gerätewechsel konnte ein altes Telefon die Geräteliste auf diesem Computer löschen. Automatische Geräte-Löschmeldungen wirken nicht mehr; Umzugsdaten werden über einmalige Empfangsbestätigungen ausgetauscht.\n- Sobald das lokale Netzwerk bereit ist, wird der dedicate Loopback-Port automatisch geprüft, damit eine einzelne Zeitüberschreitung nicht mehr fälschlich als Portkonflikt gemeldet wird.",
|
|
132
|
+
"es": "- Nuevos túneles con nombre de Cloudflare: use su propio dominio como entrada fija. El túnel se crea en su cuenta de Cloudflare y se puede gestionar en el panel cuando quiera. Puede configurarlo usted mismo en el panel y pegar el token del túnel, o introducir solo un API Token y dejar que el plugin cree el túnel y el DNS. Las credenciales solo se guardan en este ordenador.\n- Corregido: al cambiar de teléfono, un teléfono antiguo podía borrar la lista de dispositivos de este ordenador. Los avisos automáticos de eliminación de dispositivos ya no surten efecto; los datos de migración se intercambian mediante recibos de un solo uso.\n- Cuando la red local está lista, se comprueba automáticamente el puerto de bucle invertido dedicado, para que un solo tiempo de espera agotado no se interprete erróneamente como conflicto de puerto.",
|
|
133
|
+
"fr": "- Nouveaux tunnels nommés Cloudflare : utilisez votre propre domaine comme entrée fixe. Le tunnel est créé dans votre compte Cloudflare et peut être géré à tout moment dans le tableau de bord. Configurez-le vous-même dans le tableau de bord et collez le jeton du tunnel, ou saisissez uniquement un API Token et laissez le plugin créer le tunnel et le DNS pour vous. Les identifiants restent uniquement sur cet ordinateur.\n- Corrigé : après un changement de téléphone, un ancien téléphone pouvait effacer la liste des appareils de cet ordinateur. Les notifications de suppression automatique d'appareil ne s'appliquent plus ; les données de migration s'échangent via des reçus à usage unique.\n- Dès que le réseau local est prêt, le port de bouclage dédié est vérifié automatiquement, afin qu'un simple dépassement de délai ne soit plus interprété à tort comme un conflit de port.",
|
|
134
|
+
"pt": "- Novos túneis nomeados do Cloudflare: use o seu próprio domínio como entrada fixa. O túnel é criado na sua conta Cloudflare e pode ser gerido no painel a qualquer momento. Configure-o você mesmo no painel e cole o token do túnel, ou introduza apenas um API Token e deixe o plugin criar o túnel e o DNS por si. As credenciais ficam apenas neste computador.\n- Corrigido: ao trocar de telemóvel, um telemóvel antigo podia apagar a lista de dispositivos deste computador. Os avisos automáticos de eliminação de dispositivos deixaram de ter efeito; os dados de migração são trocados por recibos de uso único.\n- Assim que a rede local está pronta, a porta de loopback dedicada é verificada automaticamente, para que um único tempo limite não seja interpretado por engano como conflito de porta.",
|
|
135
|
+
"ru": "- Добавлены именованные туннели Cloudflare: используйте свой домен как постоянный вход. Туннель создаётся в вашей учётной записи Cloudflare и может управляться в панели в любое время. Настройте его самостоятельно в панели и вставьте токен туннеля либо введите только API Token и позвольте плагину создать туннель и DNS. Учётные данные хранятся только на этом компьютере.\n- Исправлено: после смены телефона старый телефон мог очистить список устройств на этом компьютере. Автоматические уведомления об удалении устройств больше не действуют; данные переноса передаются через одноразовые подтверждения.\n- Как только локальная сеть готова, выделенный порт loopback проверяется автоматически, чтобы один тайм-аут не расценивался ошибочно как конфликт портов.",
|
|
136
|
+
"tr": "- Cloudflare adlandırılmış tüneller eklendi: kendi alan adınızı sabit giriş olarak kullanın. Tünel kendi Cloudflare hesabınızda oluşturulur ve panelden istediğiniz zaman yönetilebilir. Tüneli panelde kendiniz kurup tünel token'ını yapıştırabilir veya yalnızca bir API Token girerek tünel ve DNS'i eklentinin sizin için oluşturmasını sağlayabilirsiniz. Kimlik bilgileri yalnızca bu bilgisayarda saklanır.\n- Düzeltildi: telefon değiştirildiğinde eski bir telefon bu bilgisayardaki cihaz listesini silebiliyordu. Otomatik cihaz silme bildirimleri artık geçerli değil; taşıma verileri tek kullanımlık makbuzlarla alınıp veriliyor.\n- Yerel ağ hazır olduğunda ayrılmış loopback bağlantı noktası otomatik olarak kontrol edilir; tek bir zaman aşımı yanlışlıkla bağlantı noktası çakışması olarak yorumlanmaz."
|
|
136
137
|
}
|
|
137
138
|
}
|
|
138
139
|
}
|