CVE-2026-72042: ipmi: Fix user refcount underflow in event delivery

Greg Kroah-Hartman <[email protected]>
Newsgroups org.kernel.vger.linux-cve-announce
Message-ID <2026081513-CVE-2026-72042-3b9c@gregkh>
From: Greg Kroah-Hartman <[email protected]>

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

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

ipmi: Fix user refcount underflow in event delivery

ipmi_alloc_recv_msg(user) takes the temporary user reference owned by the
receive message, and ipmi_free_recv_msg() drops it again. If event delivery
fails after allocating receive messages for earlier users,
handle_read_event_rsp() rolls those messages back with
ipmi_free_recv_msg().

That rollback path still drops user->refcount explicitly after freeing each
message. The extra put can free a user that remains linked on intf->users,
so later event delivery may dereference a freed user or trip refcount_t's
addition-on-zero warning when ipmi_alloc_recv_msg() tries to acquire
another reference.

Remove the stale explicit put and the now-dead user assignment. Keep the
list_del() and ipmi_free_recv_msg() calls; they are the required rollback
operations.

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


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

	Issue introduced in 6.18 with commit b52da4054ee0bf9ecb44996f2c83236ff50b3812 and fixed in 6.18.40 with commit ddbb6e3dc9bb4743de686aa1598c31e745cee76b
	Issue introduced in 6.18 with commit b52da4054ee0bf9ecb44996f2c83236ff50b3812 and fixed in 7.1.5 with commit 7be349d4fcc5e065295b83418a22d27a68afbdb6
	Issue introduced in 6.18 with commit b52da4054ee0bf9ecb44996f2c83236ff50b3812 and fixed in 7.2-rc1 with commit 6aa9e61c46465d231e9beddf56af7effd71be682
	Issue introduced in 6.1.157 with commit f63723ca7d7623f9dae1990973cd158671f03c56
	Issue introduced in 6.6.113 with commit 348121b29594d42d1635648fd3ed31dfa25351d5
	Issue introduced in 6.12.54 with commit 53d6e403affbf6df2c859a0ea00ccfc1e72090ca
	Issue introduced in 6.17.4 with commit 0ed73be9a2547ffb9b5c1d879ad9bfab73d920b5

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-72042
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/char/ipmi/ipmi_msghandler.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/ddbb6e3dc9bb4743de686aa1598c31e745cee76b
	https://git.kernel.org/stable/c/7be349d4fcc5e065295b83418a22d27a68afbdb6
	https://git.kernel.org/stable/c/6aa9e61c46465d231e9beddf56af7effd71be682
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.