posix-cpu-timers: Fix pid refcount leak in do_cpu_nanosleep() error path
- Published
- Last modified
- Where the record stands: published, rejected by its publisher, or superseded by another id.What do these mean? →
- published
- Whether CISA lists it in its Known Exploited Vulnerabilities catalog: proof that attackers are using it.What do these mean? →
- Not listed in CISA KEV
- Fix
- Fixed in 5.10.261, 5.15.212, 6.1.178, 6.6.145, 6.12.96, and 2 more
- Whether working attack code is public (Exploit-DB, Metasploit, Nuclei or GitHub). Public code makes attacks easier.What do these mean? →
- None on Exploit-DB, Metasploit or GitHub
Summary
In the Linux kernel, the following vulnerability has been resolved: posix-cpu-timers: Fix pid refcount leak in do_cpu_nanosleep() error path In do_cpu_nanosleep(), posix_cpu_timer_create() takes a pid reference via get_pid() and stores it in timer.it.cpu.pid. If the subsequent posix_cpu_timer_set() call fails, the function returns immediately without calling posix_cpu_timer_del() to release the pid reference, causing a leak. Fix it by calling posix_cpu_timer_del() before the unlock-and-return on the error path, consistent with the other exit paths in the same function.
Timeline
- CVE published
- Record last updated
Affected versions
- Linux Linux
From 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 · fixed in afed3cdc1cca133f804fcf57ff228974f424b23a; From 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 · fixed in 8a270b1258797f61b61da44f8bfd41a581b5c85b; From 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 · fixed in d605d00085adc3fddf67de01dc2a44aebf1a3fb5; From 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 · fixed in e5ffc638faf5dc7d9dc85c9a95e10bf97442e0c0; From 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 · fixed in eb4cec29a78334d09bcfb41c0660cdd62ba05843; From 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 · fixed in 7776f9226e99eb49d97492b0b445027cfcb189da; From 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 · fixed in 8f06363446c5d043c9a7c008b250040e9de98cf9; From 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 · fixed in 87bd2ad568e15b90d5f7d4bcd70342d05dad649c
- Linux Linux
2.6.12
- KernelLinux
From 2.6.12 · fixed in 5.10.261; From 5.11.0 · fixed in 5.15.212; From 5.16.0 · fixed in 6.1.178; From 6.2.0 · fixed in 6.6.145; From 6.7.0 · fixed in 6.12.96; From 6.13.0 · fixed in 6.18.39; From 6.19.0 · fixed in 7.1.4
References 8
git.kernel.org
- stable/c/afed3cdc1cca133f804fcf57ff228974f424b23a
- stable/c/8a270b1258797f61b61da44f8bfd41a581b5c85b
- stable/c/d605d00085adc3fddf67de01dc2a44aebf1a3fb5
- stable/c/e5ffc638faf5dc7d9dc85c9a95e10bf97442e0c0
- stable/c/eb4cec29a78334d09bcfb41c0660cdd62ba05843
- stable/c/7776f9226e99eb49d97492b0b445027cfcb189da
- stable/c/8f06363446c5d043c9a7c008b250040e9de98cf9
- stable/c/87bd2ad568e15b90d5f7d4bcd70342d05dad649c