Fix: keep the local FRP address and align the MCP read-only preset

A subordinate that already runs its own FRP proxy must keep advertising
its own master address: the upstream auto FRP is only a fallback entry
and should not overwrite the address baked into generated clients and
kernel payloads. GetEffectiveMasterAddress now returns the local address
when [frp] UseFrp is on and a master address is configured; otherwise the
upstream address is used exactly as before. The startup banner, the hot
switch tips and the settings dialog follow the same rule, and the dialog
now explains under the field when the address is supplied by the
upstream FRP.

The MCP settings dialog's read-only preset now unchecks every other tool
switch (file transfer, host management, chat, keylog), matching the smart
preset and the first-open state; previously Smart followed by Read-only
left those four checked.

The FRP auto-proxy messages now go through _TRF and the three language
files carry the new local-FRP variants and the upstream-address hint.

Verified: build.cmd server passes; the default (no local FRP) path is
unchanged.

Co-Authored-By: deepseek-flash
This commit is contained in:
yuanyuanxianganddeepseek-flash committed 2026-11-28 10:27:20 +01:00
1 parent a6c417a061
commit b0e172bf91
7 files changed
+58 -8

No files matched your search

+5
View File
@@ -2273,3 +2273,8 @@ APK
; MCP settings preset buttons
只读模式=唯讀模式
智能模式=智慧模式
; FRP auto proxy messages (local FRP precedence)
[FRP] 已启用上级 FRP 反向代理(远程端口 %d);本地 FRP 已启用,主控地址保持不变=[FRP] 已啟用上級 FRP 反向代理(遠端連接埠 %d);本機 FRP 已啟用,主控位址保持不變
[FRP] 上级 FRP 反向代理配置已切换(远程端口 %d → %d);本地 FRP 已启用,主控地址保持不变=[FRP] 上級 FRP 反向代理設定已切換(遠端連接埠 %d → %d);本機 FRP 已啟用,主控位址保持不變
; FRP address hint (upstream-provided)
该地址由上级自动 FRP 提供(端口由上级分配),无需修改=此位址由上級自動 FRP 提供(連接埠由上級分配),無需修改