Overview
About vulnerability
In the Linux kernel, the following vulnerability has been resolved:
nilfs2: fix null-ptr-deref in block_touch_buffer tracepoint
Patch series “nilfs2: fix null-ptr-deref bugs on block tracepoints”.
This series fixes null pointer dereference bugs that occur when using nilfs2 and two block-related tracepoints.
This patch (of 2):
It has been reported that when using “block:block_touch_buffer” tracepoint, touch_buffer() called from __nilfs_get_folio_block() causes a NULL pointer dereference, or a general protection fault when KASAN is enabled.
This happens because since the tracepoint was added in touch_buffer(), it references the dev_t member bh->b_bdev->bd_dev regardless of whether the buffer head has a pointer to a block_device structure. In the current implementation, the block_device structure is set after the function returns to the caller.
Here, touch_buffer() is used to mark the folio/page that owns the buffer head as accessed, but the common search helper for folio/page used by the caller function was optimized to mark the folio/page as accessed when it was reimplemented a long time ago, eliminating the need to call touch_buffer() here in the first place.
So this solves the issue by eliminating the touch_buffer() call itself.
Details
- Affected product:
- AlmaLinux 9.2 ESU , Amazon Linux 2 ELS , CentOS 7 ELS , CentOS 8.4 ELS , CentOS 8.5 ELS , CentOS Stream 8 ELS , CloudLinux 7 ELS , Debian 10 ELS , Oracle Linux 7 ELS , RHEL 7 ELS , TuxCare 9.6 ESU , Ubuntu 16.04 ELS , Ubuntu 18.04 ELS , Ubuntu 20.04 ELS
- Affected packages:
- kernel @ 5.14.0-11 (+16 more)
Fixes
KernelCare state
Live-patch status from KernelCare for each operating system.
| Operating system | Status | Covered kernels |
|---|---|---|
| Amazon Linux 2023 | Planned | — |
| Amazon Linux 2 5.10 | Will Not Fix | — |
| Debian 11 | Planned | — |
| Debian 11 cloud | Planned | — |
| Oracle Linux 7 UEK 6 | Released |
112 kernels
|
| Oracle Linux 8 UEK 6 | Released |
116 kernels
|
| Oracle Linux 8 UEK 7 | Released |
53 kernels
|
| Oracle Linux 9 UEK 7 | Released |
53 kernels
|
| Proxmox VE 7 5.15 | Released |
47 kernels
|
| Ubuntu 16.04 AWS HWE ESM | Will Not Fix | — |
| Ubuntu 16.04 Azure ESM | Will Not Fix | — |
| Ubuntu 16.04 GCP ESM | Will Not Fix | — |
| Ubuntu 16.04 HWE ESM | Will Not Fix | — |
| Ubuntu 18.04 | Will Not Fix | — |
| Ubuntu 18.04 AWS | Will Not Fix | — |
| Ubuntu 18.04 AWS Focal | Released |
56 kernels
|
| Ubuntu 18.04 Azure | Will Not Fix | — |
| Ubuntu 18.04 GCP | Will Not Fix | — |
| Ubuntu 18.04 HWE Focal | Released |
69 kernels
|
| Ubuntu 20.04 | Released |
122 kernels
|
| Ubuntu 20.04 AWS | Released |
105 kernels
|
| Ubuntu 20.04 Azure | Released |
95 kernels
|
| Ubuntu 20.04 GCP | Released |
28 kernels
|
| Ubuntu 20.04 HWE AWS | Released |
52 kernels
|
| Ubuntu 20.04 HWE Azure | Released |
36 kernels
|
| Ubuntu 22.04 | Released |
69 kernels
|
| Ubuntu 22.04 AWS | Released |
60 kernels
|
| Ubuntu 22.04 Azure | Released |
56 kernels
|
| Ubuntu 24.04 | Released |
20 kernels
|
| Ubuntu 24.04 AWS | Ready For Release | — |