CVE-2026-99755
ptp: fix use-after-free in extts_fifo_show() reading tsevqs unlocked
- CVSS
- —
- EPSS
- 0.17% (p6)
- Published
- 2026-11-20
- Age
- 14d old
- Modified
- 2026-12-01
- Product
- Linux Linux
Description
In the Linux kernel, the following vulnerability has been resolved: ptp: fix use-after-free in extts_fifo_show() reading tsevqs unlocked extts_fifo_show() walks ptp->tsevqs with list_count_nodes() and then list_first_entry() without holding ptp->tsevqs_lock, the spinlock that "protects tsevqs from concurrent access". Every other accessor of the list honours it: ptp_open() (list_add_tail), ptp_release() (list_del followed by kfree of the per-fd queue), ptp_clock_release() and ptp_clock_event() all take tsevqs_lock. extts_fifo_show() is the only one that does not. A per-fd timestamp queue is appended to tsevqs on open("/dev/ptpN") and removed and freed on close(), both under tsevqs_lock: scoped_guard(spinlock_irq, &ptp->tsevqs_lock) list_del(&queue->qlist); bitmap_free(queue->mask); kfree(queue); So a read of /sys/class/ptp/ptpN/fifo running concurrently with a close() of a /dev/ptpN fd can have list_count_nodes() walk into the queue that close() is removing and freeing, dereferencing freed memory (use-after-free) or a poisoned list pointer. Take tsevqs_lock around the list walk. The fifo only ever draws from the first queue, which is the registration-time queue created in ptp_clock_register() and freed only in ptp_clock_release(); that cannot run while the sysfs attribute is being read, so the dequeue from queue->buf under queue->lock may stay outside tsevqs_lock and the lock order is unchanged.
Fixed in
3d5d16b797a5a7131bb1a1fb81e2dfbe67aa916e · 3e83be2d6473118ef6625c00ec9bc6bf99002847 · 6.12.118 · 6.18.64 · 603a0c40d414ea12509fc45f2b930449a8d4aad2 · 6a236983e79b92d989d7179cf74927330f6606a4 · 7.3.5
Affected packages
| Ecosystem | Package | Range | Fixed |
|---|---|---|---|
| Linux | Kernel | >=6.13.0, <6.18.64 | 6.18.64 |
| Linux | Kernel | >=6.19.0, <7.3.5 | 7.3.5 |
| Linux | Kernel | >=6.7.0, <6.12.118 | 6.12.118 |
| vendor | Linux | >=d26ab5a35ad9920940a9e07665130d501b2ae1a3, <3d5d16b797a5a7131bb1a1fb81e2dfbe67aa916e | 3d5d16b797a5a7131bb1a1fb81e2dfbe67aa916e |
| vendor | Linux | >=d26ab5a35ad9920940a9e07665130d501b2ae1a3, <3e83be2d6473118ef6625c00ec9bc6bf99002847 | 3e83be2d6473118ef6625c00ec9bc6bf99002847 |
| vendor | Linux | >=d26ab5a35ad9920940a9e07665130d501b2ae1a3, <603a0c40d414ea12509fc45f2b930449a8d4aad2 | 603a0c40d414ea12509fc45f2b930449a8d4aad2 |
| vendor | Linux | >=d26ab5a35ad9920940a9e07665130d501b2ae1a3, <6a236983e79b92d989d7179cf74927330f6606a4 | 6a236983e79b92d989d7179cf74927330f6606a4 |
Sources
- NVD · first seen 14d ago · NVD terms of use
- OSV · first seen 14d ago · CC-BY 4.0
- CVE List · first seen 14d ago · CVE Terms of Use
References
- https://git.kernel.org/stable/c/3d5d16b797a5a7131bb1a1fb81e2dfbe67aa916e other
- https://git.kernel.org/stable/c/3e83be2d6473118ef6625c00ec9bc6bf99002847 other
- https://git.kernel.org/stable/c/6a236983e79b92d989d7179cf74927330f6606a4 other
- https://git.kernel.org/stable/c/603a0c40d414ea12509fc45f2b930449a8d4aad2 other
- https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git package
- https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/99xxx/CVE-2026-99755.json advisory
- https://nvd.nist.gov/vuln/detail/CVE-2026-99755 advisory