Skip to content

DefaultListener: Disable MPTCP by default - #7291

Merged
RPRX merged 2 commits into
mainfrom
mptcp
Oct 31, 2026
Merged

RPRX merged 2 commits into
mainfrom
mptcp

Conversation

@Fangliding

Copy link
Copy Markdown
Member

关闭被go默认启用的MPTCP 并使核心本来的MPTCP选项重新有效(可以手动开启)
https://thehackernews.com/2026/10/linux-kernel-tcp-flaw-with-98-cvss.html
不知是否和MPTCP强相关 可以观望一段时间 如果是真的所有go编写的翻墙服务端和caddy可以被一键获取root就搞笑了

@RPRX

RPRX commented Oct 30, 2026 •

Copy link
Copy Markdown
Member

The exploit works in two stages. First, the race makes the kernel send extra bytes back to the attacker. Once one of those replies contains a kernel address, the attacker can get around KASLR, the kernel's memory address randomization.

Second, the same bug overflows a buffer and overwrites a callback pointer with the address of a payload the attacker had already placed in kernel memory. When the kernel calls that pointer, the payload executes a shell command of the attacker's choice as root.

A lost race only fails that one connection attempt and does not crash the system, so an attacker can keep trying, the company said. In its test, leaking a kernel address took 48 minutes, and reaching command execution took 5 more minutes.

Red Hat says a remote attacker who can reach an exposed TCP service could trigger the race. Anthropic's root exploit, however, targeted servers with a multipath TCP listener. The post does not say whether servers without one can be taken over the same way.

确实很搞笑,远程提权路径清晰,可以确定的是 Golang 默认开的 MPTCP server 一定能被远程一键 root,只需等待一小时

(2026.11.04 补充对于 IPv4 Options 和真实网络链路的说明:#7326 (comment) )

红帽说普通 TCP server 也能被 trigger the race 但没说能不能被提权,如果能的话那就更搞笑了,先等一天看看

好消息是安卓 root 又有了新方案,最后希望 TCP client 别受影响吧,不然那就太炸了,个人设备很少积极更新 Linux 内核

@Fangliding

Copy link
Copy Markdown
Member Author

就算无关我也觉得可以改 可以恢复之前坏掉的参数还有某个陈年旧 sockopt bug

@RPRX

RPRX commented Oct 31, 2026 •

Copy link
Copy Markdown
Member

看了些资料,虽然所有 IPv4 TCP 监听都受影响,但 MPTCP 极为容易被远程拿 root,不然 Anthropic 直接针对普通 TCP 就行了

https://nvd.nist.gov/vuln/detail/cve-2026-98432 A similar issue exists with request socket migration (net.ipv4.tcp_migrate_req=1, or a BPF_SK_REUSEPORT_SELECT_OR_MIGRATE program).

上面这俩也是,好在用这俩的不多,不像 Go 1.24+ 默认开了 MPTCP 那么严重

https://groups.google.com/g/golang-announce/c/PCoQcdxoScw/m/aD-MgXEvAAAJ
golang/go#82717

虽然 Golang 团队的声明也占理,但对于 Xray 绝大多数用户而言,他们 Linux 服务器上 serve IPv4 MPTCP 的程序只有 Xray 等 Go 写的代理服务端,所以我认为应当默认关掉 MPTCP、按安全更新发,这能显著减小攻击面,顺便提醒用户更新 Linux 内核

又多想了一点:该漏洞不止影响 Linux 服务端,安卓客户端的 Socks/HTTP 入站若开启了“允许来自局域网的连接”则也有点危险


另外鉴于 Go 常被用于写代理且 1.24+ 默认开了 MPTCP,不确定 GFW 有没有“加分”,而 REALITY 被动默认开它显然更不太对劲


2026.11.04 补充对于 IPv4 Options 和真实网络链路的说明:#7326 (comment)

@RPRX RPRX changed the title Disable default MPTCP listener DefaultListener: Disable MPTCP by default Oct 31, 2026
@RPRX
RPRX merged commit 6ea0ab5 into main Oct 31, 2026
46 checks passed
iluobei pushed a commit to iluobei/Xray-core-mmwx that referenced this pull request Oct 31, 2026
poshelnahrenmamkinhacker pushed a commit to zapret-discordyoutube/vpnbot-xray-patches that referenced this pull request Oct 31, 2026
…-2026-98432)

CVE-2026-98432 — use-after-free в обработке запросных сокетов IPv4 TCP,
удалённо эксплуатируемый через MPTCP-слушатель; Go 1.24+ слушает с MPTCP
по умолчанию, Xray-core v26.10.31 выключил это (XTLS/Xray-core#7291).
Регресс в апстриме или в наших патчах не должен доехать до флота.

scripts/check_no_mptcp_listener.py запускает собранный xray с одним
входом на loopback в собственном сетевом пространстве (unshare -rn: там
net.mptcp.enabled по умолчанию 1, что бы ни поставил хост или раннер) и
спрашивает ядро (ss -M), MPTCP ли это слушатель. Сначала положительный
контроль: MPTCP-сокет Python обязан быть виден; не видно — отказ «не могу
судить», а не ложный зелёный.

Промоутер проверяет Xray-linux-64.zip кандидата до установки на
канарейку (assert_no_mptcp_listener), проба несёт
candidate_opens_no_mptcp_listener. Проверено в песочнице юнита
промоутера: v26.10.31-vpnbot.1 — passed, v26.9.9-vpnbot.1 — FAILED.

Claude-Session: 466471ef-a9b5-48ab-a9e8-17615b0d47c4
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Fearless743 added a commit to Fearless743/Xray-core that referenced this pull request Oct 31, 2026
Go 1.24+ 的 net.ListenConfig 默认以 MPTCP 创建 TCP listener,而
CVE-2026-98432(IPv4 TCP 建连路径 use-after-free,内核 CVE 团队评分 9.8)
可经 MPTCP listener 被远程提权到 root。

- 默认调用 lc.SetMultipathTCP(false)
- sockopt.TcpMptcp 仍可显式开启,并顺带修复 tcpMptcp:false 从未生效的问题

Refs: XTLS#7291
Fearless743 added a commit to Fearless743/Fboard-Node that referenced this pull request Oct 31, 2026
Go 1.24+ 的 net.ListenConfig 默认以 MPTCP 创建 TCP listener,CVE-2026-98432
(IPv4 TCP 建连路径 use-after-free,内核 CVE 团队评分 9.8)可经 MPTCP
listener 被远程提权到 root。节点此前 pin 的 Xray-core 未做处理,所有
VMess/VLESS/Trojan/SS 入站端口都是 MPTCP listener。

上游 XTLS/Xray-core#7291 已默认 SetMultipathTCP(false),本提交把 pin 提升到
包含该修复的 04e82ed3,使代理入站恢复为普通 TCP;sockopt.tcpMptcp 仍可按需
显式开启。节点自身的 health 端口(默认 :65530,见 cmd/fboard-node/main.go:64)
仍为裸 net.Listen,未包含在本次修改内。

make test 全绿。
shigalin added a commit to shigalin/Xray-core that referenced this pull request Oct 31, 2026
This reverts commit 6ea0ab5.

内核已修复 CVE-2026-98432,恢复 Go 默认开启的服务端 MPTCP。

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@matttbe

matttbe commented Oct 31, 2026

Copy link
Copy Markdown

I don't think that's the right fix: disabling MPTCP by default will not protect you from the issue: people should instead upgrade their kernel or block IPv4 options (which is certainly already done somewhere on the way between clients and servers). Plus this modification impacts clients benefiting from MPTCP.

Can we revert it, please? :)

@Balnea

Balnea commented Nov 1, 2026

Copy link
Copy Markdown

@MoRanYue

MoRanYue commented Nov 2, 2026

Copy link
Copy Markdown

(所有Android手机均可以越狱。如果有SELinux宽容漏洞,便可解锁Bootloader了呀())

flyoverhead added a commit to flyoverhead/docker that referenced this pull request Nov 2, 2026
#23)

Every role's image default moves to the current upstream release:
alertmanager v0.34.2, caddy 2.11.7, dnscrypt 2.1.20, grafana 13.3.0,
pihole 2026.10.1, prometheus v3.15.1, singbox v1.13.21, torrserver
MatriX.148 and xray 26.10.31. node_exporter v1.12.1 is still the newest.
The examples, the integration test pins and the README table follow.

xray 26.10.31 is an upstream security release (XTLS/Xray-core#7291): Go
1.24+ listens with MPTCP by default, and a Linux kernel bug makes the IPv4
MPTCP listener remotely exploitable. The release stops listening with
MPTCP and moves golang.org/x/net to v0.61.0. The role default was still
26.7.28.

xray_tuning_config now sets net.mptcp.enabled to 0, so no other process on
the host can open an MPTCP listener either. Like the other tuning keys it
applies only when xray_tuning_config.enabled is true; the default stays
off.

singbox stays on 1.13: 1.14 changes undefined rule-set matching and
hijacks interface DNS by default, which needs a review of the role's
config before adopting it.

Not proven: no integration run. Every new tag was checked to exist in its
registry, and yamllint, ansible-lint and the collection build pass.

Signed-off-by: flyoverhead <[email protected]>
yamatu pushed a commit to yamatu/yabx that referenced this pull request Nov 3, 2026
Go 1.24+ turns on MPTCP for every TCP listener, which is the path the
public remote-root exploit for CVE-2026-98432 uses. Mirror XTLS/Xray-core#7291
via //go:debug multipathtcp=0 so xray, sing-box and all other listeners
default to plain TCP; explicit tcpMptcp / tcp_multi_path still opt in.

Co-Authored-By: Claude Opus 4.7 <[email protected]>
@RPRX

RPRX commented Nov 4, 2026 •

Copy link
Copy Markdown
Member

2026.11.04 补充对于 IPv4 Options 和真实网络链路的说明:#7326 (comment)

Hotelk52339 added a commit to olcOS/olcos-core that referenced this pull request Nov 6, 2026
…net modules

xray-core v26.10.31 (a4a3dff5b20c) is the current release and the first that leaves MPTCP off on its listeners (XTLS/Xray-core#7291). andybalholm/brotli v1.2.8, klauspost/compress v1.20.3 and golang.org/x/net v0.62.0 carry the fixes for GO-2026-6888, GO-2026-6865 and the x/net advisories reported against the previous versions.
Hotelk52339 added a commit to olcOS/olcos-core that referenced this pull request Nov 6, 2026
Xray-core v26.10.31 is the urgent security release that leaves MPTCP off on its listeners (XTLS/Xray-core#7291): the published root exploit for CVE-2026-98432 goes through an IPv4 MPTCP listener, and Go 1.24+ listens with MPTCP by default. The installer also sets net.mptcp.enabled=0 for the host (OLCOS_KEEP_MPTCP=1 leaves it as it is); a patched kernel is still the real fix. The tls ping output format is unchanged in 26.10.31.
Hotelk52339 added a commit to olcOS/olcos-core that referenced this pull request Nov 6, 2026
Xray-core v26.10.31 is the urgent security release that leaves MPTCP off on its listeners (XTLS/Xray-core#7291): the published root exploit for CVE-2026-98432 goes through an IPv4 MPTCP listener, and Go 1.24+ listens with MPTCP by default. The installer also sets net.mptcp.enabled=0 for the host (OLCOS_KEEP_MPTCP=1 leaves it as it is); a patched kernel is still the real fix. The tls ping output format is unchanged in 26.10.31.
black-raison-detre added a commit to black-raison-detre/Xray-core that referenced this pull request Nov 7, 2026
Backport upstream XTLS#7225, XTLS#7327, XTLS#7236, and XTLS#7291 onto the
v26.7.11 maintenance branch with focused regression coverage.

Co-authored-by: Codex <[email protected]>
usehoplite Bot added a commit to vmhlov/autoXRAY that referenced this pull request Nov 9, 2026
…data and cert fixes

- New VLESS XHTTP SPLIT config (upload via REALITY:443, download via TLS:8443);
  both XHTTP paths now terminate in a single inbound so sessions can be joined
- Disable MPTCP via sysctl and require Xray >= 26.10.31 (XTLS/Xray-core#7291)
- Drop geosite categories missing from the installer's bundled geodata
  (win-spy on servers, win-update/win-extra on the bridge) so Xray starts
- Private key copied as 640 root:xray via a deploy hook instead of chmod 744
- Allow 1.5MB XHTTP POSTs on the server to match client extra (fixes 413)
- freedom.domainStrategy -> sockopt.domainStrategy; remove dead /ssws fallback
- Fix final output printing the REALITY link under XHTTP TLS

Co-authored-by: Hoplite <288093033+usehoplite[bot]@users.noreply.github.com>
usehoplite Bot added a commit to vmhlov/autoXRAY that referenced this pull request Nov 9, 2026
…xray

- Pin Xray to v26.11.9 (Chrome 155 default fingerprint, XDRIVE transport)
- net.mptcp.enabled=0 (XTLS/Xray-core#7291)
- Private key was chmod 644 (world-readable); Xray runs as user xray,
  so 640 root:xray is sufficient (nginx never reads the key)
- README: UPD6 entry, XDRIVE and MPTCP sections; install URLs for the
  modified scripts point to this fork

Co-authored-by: Hoplite <288093033+usehoplite[bot]@users.noreply.github.com>
meqx01 added a commit to icecompany-tech/iceslab that referenced this pull request Nov 10, 2026
…eally closes dead connections on Ubuntu nodes (Bk-170)

xray 26.3.27 is built with Go 1.26. Go 1.24+ opens listeners as MPTCP by
default where the kernel has MPTCP on (Ubuntu, the CI runner), and on an
MPTCP socket TCP_USER_TIMEOUT is refused with EOPNOTSUPP. The option was
rendered, xray logged the failure at info, and the socket kept 0: a
connection with data in flight to a dead peer stayed open. Keepalive is
taken by MPTCP and worked. Read off the core's own sockets on aeza-de-01
(kernel 7.0) and on the runner: listener TCP_USER_TIMEOUT=0 "operation not
supported"; with GODEBUG=multipathtcp=0 it is 3000 and the connection
closes in 3.2 s.

The agent now starts xray with GODEBUG=multipathtcp=0, appended after an
operator's own GODEBUG so the rest of it is kept. Xray itself turns MPTCP
off by default from v26.10.31 (XTLS/Xray-core#7291); the pin moves there
as a separate task. The process settings live in one function,
processConfig, and the test reads the environment of a process started
from it. The live sockopt test sets no GODEBUG of its own: it starts xray
through the adapter and gets the setting from the agent.
Fearless743 added a commit to Fearless743/Fboard-Node that referenced this pull request Nov 10, 2026
Go 1.24+ 的 net.ListenConfig 默认以 MPTCP 创建 TCP listener,CVE-2026-98432
(IPv4 TCP 建连路径 use-after-free,内核 CVE 团队评分 9.8)可经 MPTCP
listener 被远程提权到 root。节点此前 pin 的 Xray-core 未做处理,所有
VMess/VLESS/Trojan/SS 入站端口都是 MPTCP listener。

上游 XTLS/Xray-core#7291 已默认 SetMultipathTCP(false),本提交把 pin 提升到
包含该修复的 04e82ed3,使代理入站恢复为普通 TCP;sockopt.tcpMptcp 仍可按需
显式开启。节点自身的 health 端口(默认 :65530,见 cmd/fboard-node/main.go:64)
仍为裸 net.Listen,未包含在本次修改内。

make test 全绿。
@RPRX
RPRX deleted the mptcp branch November 19, 2026 12:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants