Skip to contentSkip to conversation

CVE-2026-43163: md/bitmap: fix GPF in write_page caused by resize race

DISCUSSION Greg Kroah-Hartman 1 participant 1 message May 6

lore
Share & tools
lore
#0 lore raw

From: Greg Kroah-Hartman <[email protected]>

Description
===========

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

md/bitmap: fix GPF in write_page caused by resize race

A General Protection Fault occurs in write_page() during array resize:

RIP: 0010:write_page+0x22b/0x3c0 [md_mod]

This is a use-after-free race between bitmap_daemon_work() and __bitmap_resize(). The daemon iterates over bitmap->storage.filemap without locking, while the resize path frees that storage via md_bitmap_file_unmap(). quiesce() does not stop the md thread, allowing concurrent access to freed pages.

Fix by holding mddev->bitmap_info.mutex during the bitmap update.

The Linux kernel CVE team has assigned CVE-2026-43163 to this issue.

Affected and fixed versions
===========================

	Issue introduced in 3.5 with commit d60b479d177a5735b6b4db6ee5280ef6653f50e7 and fixed in 5.10.252 with commit 140cc839fbeb1ddb33a8da8811b716d88d3905b7
	Issue introduced in 3.5 with commit d60b479d177a5735b6b4db6ee5280ef6653f50e7 and fixed in 5.15.202 with commit ebcacc7ca22d5e8a03a970f0621ae1d1356b9ae8
	Issue introduced in 3.5 with commit d60b479d177a5735b6b4db6ee5280ef6653f50e7 and fixed in 6.1.165 with commit d3af62411e19752c663fe4f424dbf49d95a4cc7c
	Issue introduced in 3.5 with commit d60b479d177a5735b6b4db6ee5280ef6653f50e7 and fixed in 6.6.128 with commit d92b8fac294b5f915c50e65ce4ae2262e53614ec
	Issue introduced in 3.5 with commit d60b479d177a5735b6b4db6ee5280ef6653f50e7 and fixed in 6.12.75 with commit a437e3bf30e32846079e470c1ba5ee790bccdf89
	Issue introduced in 3.5 with commit d60b479d177a5735b6b4db6ee5280ef6653f50e7 and fixed in 6.18.16 with commit 9a6f8cd28bb9bb6ed86a6df19331fb08016dee7f
	Issue introduced in 3.5 with commit d60b479d177a5735b6b4db6ee5280ef6653f50e7 and fixed in 6.19.6 with commit 5f73c8b33df9a605a591eab72d43a969600c1f8c
	Issue introduced in 3.5 with commit d60b479d177a5735b6b4db6ee5280ef6653f50e7 and fixed in 7.0 with commit 46ef85f854dfa9d5226b3c1c46493d79556c9589

Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community.

Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at

	https://cve.org/CVERecord/?id=CVE-2026-43163

will be updated if fixes are backported, please check that for the most up to date information about this issue.

Affected files
==============

The file(s) affected by this issue are:
drivers/md/md-bitmap.c

Mitigation
==========

The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits:

	https://git.kernel.org/stable/c/140cc839fbeb1ddb33a8da8811b716d88d3905b7
	https://git.kernel.org/stable/c/ebcacc7ca22d5e8a03a970f0621ae1d1356b9ae8
	https://git.kernel.org/stable/c/d3af62411e19752c663fe4f424dbf49d95a4cc7c
	https://git.kernel.org/stable/c/d92b8fac294b5f915c50e65ce4ae2262e53614ec
	https://git.kernel.org/stable/c/a437e3bf30e32846079e470c1ba5ee790bccdf89
	https://git.kernel.org/stable/c/9a6f8cd28bb9bb6ed86a6df19331fb08016dee7f
	https://git.kernel.org/stable/c/5f73c8b33df9a605a591eab72d43a969600c1f8c
	https://git.kernel.org/stable/c/46ef85f854dfa9d5226b3c1c46493d79556c9589