# CVE-2025-40257: mptcp: fix a race in mptcp\_pm\_del\_add\_timer()

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** CRITICAL 9.8
- **CVSS:** 9.8 (v3.1, CNA) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`
- **CVSS metrics:** Attack vector: Network; Attack complexity: Low; Privileges required: None; User interaction: None; Scope: Unchanged; Confidentiality impact: High; Integrity impact: High; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Remote, no login needed
- **EPSS:** 0.97% (percentile 61, 2026-11-26)
- **Published:** 2025-12-04T16:08:18.433Z
- **Modified:** 2026-10-19T21:10:00.160Z

## Who should check

- Anyone running Linux \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< 9be29f8e7ce4e147e56caac2c3a0ce3573cf9c17; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< e2d1ad207174a7cd7903dd27a00db4b2dfa6c64b; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< 385ddc0f008f24d1e7d03be998b3a98a37bd29ff; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< c602cc344b4b8d41515fec3ffa98457ac963ee12; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< 6d3275d4ca62e2c02e1b7e8cd32db59df91c14b7; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< bbbd75346c8e6490b19c2ba90f38ea66ccf352b2; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< 426358d9be7ce3518966422f87b96f1bad27295f
- Anyone running Linux 5.10

## Description

In the Linux kernel, the following vulnerability has been resolved:

mptcp: fix a race in mptcp\_pm\_del\_add\_timer()

mptcp\_pm\_del\_add\_timer() can call sk\_stop\_timer\_sync(sk, &entry-\>add\_timer)
while another might have free entry already, as reported by syzbot.

Add RCU protection to fix this issue.

Also change confusing add\_timer variable with stop\_timer boolean.

syzbot report:

BUG: KASAN: slab-use-after-free in \_\_timer\_delete\_sync+0x372/0x3f0 kernel/time/timer.c:1616
Read of size 4 at addr ffff8880311e4150 by task kworker/1:1/44

CPU: 1 UID: 0 PID: 44 Comm: kworker/1:1 Not tainted syzkaller \#0 PREEMPT\_{RT,(full)}
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/02/2025
Workqueue: events mptcp\_worker
Call Trace:
 \<TASK\>
  dump\_stack\_lvl+0x189/0x250 lib/dump\_stack.c:120
  print\_address\_description mm/kasan/report.c:378 \[inline\]
  print\_report+0xca/0x240 mm/kasan/report.c:482
  kasan\_report+0x118/0x150 mm/kasan/report.c:595
  \_\_timer\_delete\_sync+0x372/0x3f0 kernel/time/timer.c:1616
  sk\_stop\_timer\_sync+0x1b/0x90 net/core/sock.c:3631
  mptcp\_pm\_del\_add\_timer+0x283/0x310 net/mptcp/pm.c:362
  mptcp\_incoming\_options+0x1357/0x1f60 net/mptcp/options.c:1174
  tcp\_data\_queue+0xca/0x6450 net/ipv4/tcp\_input.c:5361
  tcp\_rcv\_established+0x1335/0x2670 net/ipv4/tcp\_input.c:6441
  tcp\_v4\_do\_rcv+0x98b/0xbf0 net/ipv4/tcp\_ipv4.c:1931
  tcp\_v4\_rcv+0x252a/0x2dc0 net/ipv4/tcp\_ipv4.c:2374
  ip\_protocol\_deliver\_rcu+0x221/0x440 net/ipv4/ip\_input.c:205
  ip\_local\_deliver\_finish+0x3bb/0x6f0 net/ipv4/ip\_input.c:239
  NF\_HOOK+0x30c/0x3a0 include/linux/netfilter.h:318
  NF\_HOOK+0x30c/0x3a0 include/linux/netfilter.h:318
  \_\_netif\_receive\_skb\_one\_core net/core/dev.c:6079 \[inline\]
  \_\_netif\_receive\_skb+0x143/0x380 net/core/dev.c:6192
  process\_backlog+0x31e/0x900 net/core/dev.c:6544
  \_\_napi\_poll+0xb6/0x540 net/core/dev.c:7594
  napi\_poll net/core/dev.c:7657 \[inline\]
  net\_rx\_action+0x5f7/0xda0 net/core/dev.c:7784
  handle\_softirqs+0x22f/0x710 kernel/softirq.c:622
  \_\_do\_softirq kernel/softirq.c:656 \[inline\]
  \_\_local\_bh\_enable\_ip+0x1a0/0x2e0 kernel/softirq.c:302
  mptcp\_pm\_send\_ack net/mptcp/pm.c:210 \[inline\]
 mptcp\_pm\_addr\_send\_ack+0x41f/0x500 net/mptcp/pm.c:-1
  mptcp\_pm\_worker+0x174/0x320 net/mptcp/pm.c:1002
  mptcp\_worker+0xd5/0x1170 net/mptcp/protocol.c:2762
  process\_one\_work kernel/workqueue.c:3263 \[inline\]
  process\_scheduled\_works+0xae1/0x17b0 kernel/workqueue.c:3346
  worker\_thread+0x8a0/0xda0 kernel/workqueue.c:3427
  kthread+0x711/0x8a0 kernel/kthread.c:463
  ret\_from\_fork+0x4bc/0x870 arch/x86/kernel/process.c:158
  ret\_from\_fork\_asm+0x1a/0x30 arch/x86/entry/entry\_64.S:245
 \</TASK\>

Allocated by task 44:
  kasan\_save\_stack mm/kasan/common.c:56 \[inline\]
  kasan\_save\_track+0x3e/0x80 mm/kasan/common.c:77
  poison\_kmalloc\_redzone mm/kasan/common.c:400 \[inline\]
  \_\_kasan\_kmalloc+0x93/0xb0 mm/kasan/common.c:417
  kasan\_kmalloc include/linux/kasan.h:262 \[inline\]
  \_\_kmalloc\_cache\_noprof+0x1ef/0x6c0 mm/slub.c:5748
  kmalloc\_noprof include/linux/slab.h:957 \[inline\]
  mptcp\_pm\_alloc\_anno\_list+0x104/0x460 net/mptcp/pm.c:385
  mptcp\_pm\_create\_subflow\_or\_signal\_addr+0xf9d/0x1360 net/mptcp/pm\_kernel.c:355
  mptcp\_pm\_nl\_fully\_established net/mptcp/pm\_kernel.c:409 \[inline\]
  \_\_mptcp\_pm\_kernel\_worker+0x417/0x1ef0 net/mptcp/pm\_kernel.c:1529
  mptcp\_pm\_worker+0x1ee/0x320 net/mptcp/pm.c:1008
  mptcp\_worker+0xd5/0x1170 net/mptcp/protocol.c:2762
  process\_one\_work kernel/workqueue.c:3263 \[inline\]
  process\_scheduled\_works+0xae1/0x17b0 kernel/workqueue.c:3346
  worker\_thread+0x8a0/0xda0 kernel/workqueue.c:3427
  kthread+0x711/0x8a0 kernel/kthread.c:463
  ret\_from\_fork+0x4bc/0x870 arch/x86/kernel/process.c:158
  ret\_from\_fork\_asm+0x1a/0x30 arch/x86/entry/entry\_64.S:245

Freed by task 6630:
  kasan\_save\_stack mm/kasan/common.c:56 \[inline\]
  kasan\_save\_track+0x3e/0x80 mm/kasan/common.c:77
  \_\_kasan\_save\_free\_info+0x46/0x50 mm/kasan/generic.c:587
  kasan\_save\_free\_info mm/kasan/kasan.h:406 \[inline\]
  poison\_slab\_object m
---truncated---

## Affected and fixed versions

- Linux: \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< 9be29f8e7ce4e147e56caac2c3a0ce3573cf9c17; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< e2d1ad207174a7cd7903dd27a00db4b2dfa6c64b; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< 385ddc0f008f24d1e7d03be998b3a98a37bd29ff; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< c602cc344b4b8d41515fec3ffa98457ac963ee12; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< 6d3275d4ca62e2c02e1b7e8cd32db59df91c14b7; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< bbbd75346c8e6490b19c2ba90f38ea66ccf352b2; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< 426358d9be7ce3518966422f87b96f1bad27295f (cvelist)
- Linux: 5.10 (cvelist)

## Mitigation

- Upgrade Linux to 426358d9be7ce3518966422f87b96f1bad27295f or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2025-40257. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2025-40257.md
Affected: Linux >= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, < 9be29f8e7ce4e147e56caac2c3a0ce3573cf9c17; >= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, < e2d1ad207174a7cd7903dd27a00db4b2dfa6c64b; >= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, < 385ddc0f008f24d1e7d03be998b3a98a37bd29ff; >= 00cfd77b9063dcdf3628a70…
Fixed in: Linux 9be29f8e7ce4e147e56caac2c3a0ce3573cf9c17, Linux 385ddc0f008f24d1e7d03be998b3a98a37bd29ff, Linux 6d3275d4ca62e2c02e1b7e8cd32db59df91c14b7, Linux 426358d9be7ce3518966422f87b96f1bad27295f

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2025-40257 being exploited?

There is no confirmed exploitation: CVE-2025-40257 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.97% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2025-40257?

Critical: CVSS 9.8 (v3.1, scored by CNA). Remote, no login needed.

### Which versions are affected by CVE-2025-40257?

Linux \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< 9be29f8e7ce4e147e56caac2c3a0ce3573cf9c17; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< e2d1ad207174a7cd7903dd27a00db4b2dfa6c64b; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< 385ddc0f008f24d1e7d03be998b3a98a37bd29ff; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< c602cc344b4b8d41515fec3ffa98457ac963ee12; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< 6d3275d4ca62e2c02e1b7e8cd32db59df91c14b7; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< bbbd75346c8e6490b19c2ba90f38ea66ccf352b2; \>= 00cfd77b9063dcdf3628a7087faba60de85a9cc8, \< 426358d9be7ce3518966422f87b96f1bad27295f; Linux 5.10.

### Is there a fix for CVE-2025-40257?

Yes. Fixed in Linux 9be29f8e7ce4e147e56caac2c3a0ce3573cf9c17, Linux 385ddc0f008f24d1e7d03be998b3a98a37bd29ff, Linux 6d3275d4ca62e2c02e1b7e8cd32db59df91c14b7, Linux 426358d9be7ce3518966422f87b96f1bad27295f. Upgrade Linux to 426358d9be7ce3518966422f87b96f1bad27295f or later.

### How do I check if I'm affected by CVE-2025-40257?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- other: <https://git.kernel.org/stable/c/9be29f8e7ce4e147e56caac2c3a0ce3573cf9c17>
- other: <https://git.kernel.org/stable/c/e2d1ad207174a7cd7903dd27a00db4b2dfa6c64b>
- other: <https://git.kernel.org/stable/c/385ddc0f008f24d1e7d03be998b3a98a37bd29ff>
- other: <https://git.kernel.org/stable/c/c602cc344b4b8d41515fec3ffa98457ac963ee12>
- other: <https://git.kernel.org/stable/c/6d3275d4ca62e2c02e1b7e8cd32db59df91c14b7>
- other: <https://git.kernel.org/stable/c/bbbd75346c8e6490b19c2ba90f38ea66ccf352b2>
- other: <https://git.kernel.org/stable/c/426358d9be7ce3518966422f87b96f1bad27295f>
- other: <https://cert-portal.siemens.com/productcert/html/ssa-253495.html>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2025-40257>

HTML: <https://flawdb.com/CVE-2025-40257> · JSON: <https://flawdb.com/api/v1/entries/CVE-2025-40257>
