Skip to contentSkip to conversation

CVE-2026-80881: ocfs2: fix buffer head management in ocfs2_read_blocks()

DISCUSSION Greg Kroah-Hartman 1 participant 1 message Sep 4

lore
Share & tools
lore
#0 lore raw

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

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

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

ocfs2: fix buffer head management in ocfs2_read_blocks()

In ocfs2_read_blocks(), caller should't assume that buffer head returned by 'sb_getblk()' is exclusively owned and so 'put_bh()' always drops b_count from 1 to 0. If it is not so, buffer head remains on hold and likely to be returned by the next call to 'sb_getblk()' unchanged - that is, with BH_Uptodate bit set even if it has failed validation previously, thus allowing to insert that buffer head into OCFS2 metadata cache and submit it to upper layers. To avoid such a scenario, BH_Uptodate should be cleared immediately after 'validate()' callback has detected some data inconsistency.

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

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

	Issue introduced in 4.20 with commit cf76c78595ca87548ca5e45c862ac9e0949c4687 and fixed in 5.10.261 with commit a4eae1499c760949a93459d11390bd1fd823d31d
	Issue introduced in 4.20 with commit cf76c78595ca87548ca5e45c862ac9e0949c4687 and fixed in 5.15.212 with commit 4ab17e328522a4df5fe0f0dcf39098118b1feeaa
	Issue introduced in 4.20 with commit cf76c78595ca87548ca5e45c862ac9e0949c4687 and fixed in 6.1.178 with commit 5927acb3e2c99985a14adecd9d1b67ba191c622d
	Issue introduced in 4.20 with commit cf76c78595ca87548ca5e45c862ac9e0949c4687 and fixed in 6.6.145 with commit ecb3f9386f4353034caef77239473c627232db17
	Issue introduced in 4.20 with commit cf76c78595ca87548ca5e45c862ac9e0949c4687 and fixed in 6.12.97 with commit 61f7a5acb3bf8fc97dad78f54b1e8d0e1c819766
	Issue introduced in 4.20 with commit cf76c78595ca87548ca5e45c862ac9e0949c4687 and fixed in 6.18.40 with commit 0e389fc290c350c67591abf4c367119f4689f310
	Issue introduced in 4.20 with commit cf76c78595ca87548ca5e45c862ac9e0949c4687 and fixed in 7.1.5 with commit 9e7a057934cdd58e4cc94350bcfe5367bbee0f8e
	Issue introduced in 4.20 with commit cf76c78595ca87548ca5e45c862ac9e0949c4687 and fixed in 7.2 with commit 6371a07148ee979af22a9d6f4c277462953a9a4a
	Issue introduced in 4.4.204 with commit 01f93d5e36753fc4d06ec67f05ce78c9c6f2dd56
	Issue introduced in 4.9.204 with commit 65cbd1279f4b999d56a838344a30642db24cd215
	Issue introduced in 4.14.157 with commit 97e1db17bc1ef4c2e1789bc9323c7be44fba53f8
	Issue introduced in 4.19.87 with commit 6c150df9c2e80b5cf86f5a0d98beb7390ad63bfc

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-80881

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:
fs/ocfs2/buffer_head_io.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/a4eae1499c760949a93459d11390bd1fd823d31d
	https://git.kernel.org/stable/c/4ab17e328522a4df5fe0f0dcf39098118b1feeaa
	https://git.kernel.org/stable/c/5927acb3e2c99985a14adecd9d1b67ba191c622d
	https://git.kernel.org/stable/c/ecb3f9386f4353034caef77239473c627232db17
	https://git.kernel.org/stable/c/61f7a5acb3bf8fc97dad78f54b1e8d0e1c819766
	https://git.kernel.org/stable/c/0e389fc290c350c67591abf4c367119f4689f310
	https://git.kernel.org/stable/c/9e7a057934cdd58e4cc94350bcfe5367bbee0f8e
	https://git.kernel.org/stable/c/6371a07148ee979af22a9d6f4c277462953a9a4a