Upstream information
Description
In the Linux kernel, the following vulnerability has been resolved:maple_tree: correct tree corruption on spanning store
Patch series "maple_tree: correct tree corruption on spanning store", v3.
There has been a nasty yet subtle maple tree corruption bug that appears
to have been in existence since the inception of the algorithm.
This bug seems far more likely to happen since commit f8d112a4e657
("mm/mmap: avoid zeroing vma tree in mmap_region()"), which is the point
at which reports started to be submitted concerning this bug.
We were made definitely aware of the bug thanks to the kind efforts of
Bert Karwatzki who helped enormously in my being able to track this down
and identify the cause of it.
The bug arises when an attempt is made to perform a spanning store across
two leaf nodes, where the right leaf node is the rightmost child of the
shared parent, AND the store completely consumes the right-mode node.
This results in mas_wr_spanning_store() mitakenly duplicating the new and
existing entries at the maximum pivot within the range, and thus maple
tree corruption.
The fix patch corrects this by detecting this scenario and disallowing the
mistaken duplicate copy.
The fix patch commit message goes into great detail as to how this occurs.
This series also includes a test which reliably reproduces the issue, and
asserts that the fix works correctly.
Bert has kindly tested the fix and confirmed it resolved his issues. Also
Mikhail Gavrilov kindly reported what appears to be precisely the same
bug, which this fix should also resolve.
This patch (of 2):
There has been a subtle bug present in the maple tree implementation from
its inception.
This arises from how stores are performed - when a store occurs, it will
overwrite overlapping ranges and adjust the tree as necessary to
accommodate this.
A range may always ultimately span two leaf nodes. In this instance we
walk the two leaf nodes, determine which elements are not overwritten to
the left and to the right of the start and end of the ranges respectively
and then rebalance the tree to contain these entries and the newly
inserted one.
This kind of store is dubbed a 'spanning store' and is implemented by
mas_wr_spanning_store().
In order to reach this stage, mas_store_gfp() invokes
mas_wr_preallocate(), mas_wr_store_type() and mas_wr_walk() in turn to
walk the tree and update the object (mas) to traverse to the location
where the write should be performed, determining its store type.
When a spanning store is required, this function returns false stopping at
the parent node which contains the target range, and mas_wr_store_type()
marks the mas->store_type as wr_spanning_store to denote this fact.
When we go to perform the store in mas_wr_spanning_store(), we first
determine the elements AFTER the END of the range we wish to store (that
is, to the right of the entry to be inserted) - we do this by walking to
the NEXT pivot in the tree (i.e. r_mas.last + 1), starting at the node we
have just determined contains the range over which we intend to write.
We then turn our attention to the entries to the left of the entry we are
inserting, whose state is represented by l_mas, and copy these into a 'big
node', which is a special node which contains enough slots to contain two
leaf node's worth of data.
We then copy the entry we wish to store immediately after this - the copy
and the insertion of the new entry is performed by mas_store_b_node().
After this we copy the elements to the right of the end of the range which
we are inserting, if we have not exceeded the length of the node (i.e.
r_mas.offset <= r_mas.end).
Herein lies the bug - under very specific circumstances, this logic can
break and corrupt the maple tree.
Consider the following tree:
Height
0 Root Node
/ \
pivot = 0xffff / \ pivot = ULONG_MAX
/
---truncated---
SUSE information
Overall state of this security issue: Resolved
This issue is currently rated as having moderate severity.
SUSE | |
---|---|
Base Score | 5.5 |
Vector | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H |
Attack Vector | Local |
Attack Complexity | Low |
Privileges Required | Low |
User Interaction | None |
Scope | Unchanged |
Confidentiality Impact | None |
Integrity Impact | None |
Availability Impact | High |
CVSSv3 Version | 3.1 |
Status of this issue by product and package
Please note that this evaluation state might be work in progress, incomplete or outdated. Also information for service packs in the LTSS phase is only included for issues meeting the LTSS criteria. If in doubt, feel free to contact us for clarification. The updates are grouped by state of their lifecycle. SUSE product lifecycles are documented on the lifecycle page.
Product(s) | Source package | State |
---|---|---|
Products under general support and receiving all security fixes. | ||
SUSE Linux Enterprise Desktop 15 SP5 | kernel-default | Not affected |
SUSE Linux Enterprise Desktop 15 SP5 | kernel-source | Not affected |
SUSE Linux Enterprise Desktop 15 SP6 | kernel-default | Not affected |
SUSE Linux Enterprise Desktop 15 SP6 | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP5 | kernel-default | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP5 | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP5 | kernel-source-azure | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP6 | kernel-default | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP6 | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP6 | kernel-source-azure | Not affected |
SUSE Linux Enterprise Live Patching 15 SP5 | kernel-default | Not affected |
SUSE Linux Enterprise Live Patching 15 SP5 | kernel-source | Not affected |
SUSE Linux Enterprise Live Patching 15 SP6 | kernel-default | Not affected |
SUSE Linux Enterprise Live Patching 15 SP6 | kernel-source | Not affected |
SUSE Linux Enterprise Micro 5.1 | kernel-default | Not affected |
SUSE Linux Enterprise Micro 5.1 | kernel-rt | Not affected |
SUSE Linux Enterprise Micro 5.1 | kernel-source | Not affected |
SUSE Linux Enterprise Micro 5.1 | kernel-source-rt | Not affected |
SUSE Linux Enterprise Micro 5.2 | kernel-default | Not affected |
SUSE Linux Enterprise Micro 5.2 | kernel-rt | Not affected |
SUSE Linux Enterprise Micro 5.2 | kernel-source | Not affected |
SUSE Linux Enterprise Micro 5.2 | kernel-source-rt | Not affected |
SUSE Linux Enterprise Micro 5.3 | kernel-default | Not affected |
SUSE Linux Enterprise Micro 5.3 | kernel-rt | Not affected |
SUSE Linux Enterprise Micro 5.3 | kernel-source | Not affected |
SUSE Linux Enterprise Micro 5.3 | kernel-source-rt | Not affected |
SUSE Linux Enterprise Micro 5.4 | kernel-default | Not affected |
SUSE Linux Enterprise Micro 5.4 | kernel-rt | Not affected |
SUSE Linux Enterprise Micro 5.4 | kernel-source | Not affected |
SUSE Linux Enterprise Micro 5.4 | kernel-source-rt | Not affected |
SUSE Linux Enterprise Micro 5.5 | kernel-default | Not affected |
SUSE Linux Enterprise Micro 5.5 | kernel-source | Not affected |
SUSE Linux Enterprise Micro 5.5 | kernel-source-rt | Not affected |
SUSE Linux Enterprise Micro 6.0 | kernel-default | Not affected |
SUSE Linux Enterprise Micro 6.0 | kernel-source | Not affected |
SUSE Linux Enterprise Micro 6.0 | kernel-source-rt | Not affected |
SUSE Linux Enterprise Module for Basesystem 15 SP5 | kernel-default | Not affected |
SUSE Linux Enterprise Module for Basesystem 15 SP5 | kernel-source | Not affected |
SUSE Linux Enterprise Module for Basesystem 15 SP6 | kernel-default | Not affected |
SUSE Linux Enterprise Module for Basesystem 15 SP6 | kernel-source | Not affected |
SUSE Linux Enterprise Module for Development Tools 15 SP5 | kernel-default | Not affected |
SUSE Linux Enterprise Module for Development Tools 15 SP5 | kernel-source | Not affected |
SUSE Linux Enterprise Module for Development Tools 15 SP6 | kernel-default | Not affected |
SUSE Linux Enterprise Module for Development Tools 15 SP6 | kernel-source | Not affected |
SUSE Linux Enterprise Module for Public Cloud 15 SP5 | kernel-source-azure | Not affected |
SUSE Linux Enterprise Module for Public Cloud 15 SP6 | kernel-source-azure | Not affected |
SUSE Linux Enterprise Real Time 15 SP5 | kernel-source-rt | Not affected |
SUSE Linux Enterprise Real Time 15 SP6 | kernel-source-rt | Not affected |
SUSE Linux Enterprise Server 15 SP5 | kernel-default | Not affected |
SUSE Linux Enterprise Server 15 SP5 | kernel-source | Not affected |
SUSE Linux Enterprise Server 15 SP5 | kernel-source-azure | Not affected |
SUSE Linux Enterprise Server 15 SP6 | kernel-default | Not affected |
SUSE Linux Enterprise Server 15 SP6 | kernel-source | Not affected |
SUSE Linux Enterprise Server 15 SP6 | kernel-source-azure | Not affected |
SUSE Linux Enterprise Server for SAP Applications 15 SP5 | kernel-default | Not affected |
SUSE Linux Enterprise Server for SAP Applications 15 SP5 | kernel-source | Not affected |
SUSE Linux Enterprise Server for SAP Applications 15 SP5 | kernel-source-azure | Not affected |
SUSE Linux Enterprise Server for SAP Applications 15 SP6 | kernel-default | Not affected |
SUSE Linux Enterprise Server for SAP Applications 15 SP6 | kernel-source | Not affected |
SUSE Linux Enterprise Server for SAP Applications 15 SP6 | kernel-source-azure | Not affected |
SUSE Manager Proxy 4.3 | kernel-default | Not affected |
SUSE Manager Proxy 4.3 | kernel-source | Not affected |
SUSE Manager Retail Branch Server 4.3 | kernel-default | Not affected |
SUSE Manager Retail Branch Server 4.3 | kernel-source | Not affected |
SUSE Manager Server 4.3 | kernel-default | Not affected |
SUSE Manager Server 4.3 | kernel-source | Not affected |
SUSE Real Time Module 15 SP5 | kernel-source-rt | Not affected |
SUSE Real Time Module 15 SP6 | kernel-source-rt | Not affected |
openSUSE Leap 15.5 | kernel-default | Not affected |
openSUSE Leap 15.5 | kernel-source | Not affected |
openSUSE Leap 15.5 | kernel-source-azure | Not affected |
openSUSE Leap 15.5 | kernel-source-rt | Not affected |
openSUSE Leap 15.6 | kernel-default | Not affected |
openSUSE Leap 15.6 | kernel-source | Not affected |
openSUSE Leap 15.6 | kernel-source-azure | Not affected |
openSUSE Leap 15.6 | kernel-source-rt | Not affected |
Products under Long Term Service Pack support and receiving important and critical security fixes. | ||
SUSE Linux Enterprise Desktop 15 SP4 | kernel-source | Not affected |
SUSE Linux Enterprise High Availability Extension 12 SP5 | kernel-default | Not affected |
SUSE Linux Enterprise High Availability Extension 12 SP5 | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 12 SP5 | kernel-default | Not affected |
SUSE Linux Enterprise High Performance Computing 12 SP5 | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 12 SP5 | kernel-source-azure | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP2 | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP2-ESPOS | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP2-LTSS | kernel-default | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP2-LTSS | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP3 | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP3-ESPOS | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP3-LTSS | kernel-default | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP3-LTSS | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP4 | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP4-ESPOS | kernel-default | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP4-ESPOS | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP4-LTSS | kernel-default | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP4-LTSS | kernel-source | Not affected |
SUSE Linux Enterprise Live Patching 12 SP5 | kernel-default | Not affected |
SUSE Linux Enterprise Live Patching 12 SP5 | kernel-source | Not affected |
SUSE Linux Enterprise Live Patching 15 SP2 | kernel-default | Not affected |
SUSE Linux Enterprise Live Patching 15 SP2 | kernel-source | Not affected |
SUSE Linux Enterprise Live Patching 15 SP3 | kernel-default | Not affected |
SUSE Linux Enterprise Live Patching 15 SP3 | kernel-source | Not affected |
SUSE Linux Enterprise Live Patching 15 SP4 | kernel-default | Not affected |
SUSE Linux Enterprise Live Patching 15 SP4 | kernel-source | Not affected |
SUSE Linux Enterprise Module for Basesystem 15 SP2 | kernel-source | Not affected |
SUSE Linux Enterprise Module for Basesystem 15 SP3 | kernel-source | Not affected |
SUSE Linux Enterprise Module for Basesystem 15 SP4 | kernel-source | Not affected |
SUSE Linux Enterprise Module for Development Tools 15 SP2 | kernel-source | Not affected |
SUSE Linux Enterprise Module for Development Tools 15 SP3 | kernel-source | Not affected |
SUSE Linux Enterprise Module for Development Tools 15 SP4 | kernel-source | Not affected |
SUSE Linux Enterprise Server 11 SP4 LTSS EXTREME CORE | kernel-default | Not affected |
SUSE Linux Enterprise Server 11 SP4 LTSS EXTREME CORE | kernel-source | Not affected |
SUSE Linux Enterprise Server 12 SP5 | kernel-default | Not affected |
SUSE Linux Enterprise Server 12 SP5 | kernel-source | Not affected |
SUSE Linux Enterprise Server 12 SP5 | kernel-source-azure | Not affected |
SUSE Linux Enterprise Server 12 SP5-LTSS | kernel-default | Not affected |
SUSE Linux Enterprise Server 12 SP5-LTSS | kernel-source | Not affected |
SUSE Linux Enterprise Server 12 SP5-LTSS | kernel-source-azure | Not affected |
SUSE Linux Enterprise Server 15 SP2 | kernel-source | Not affected |
SUSE Linux Enterprise Server 15 SP2-LTSS | kernel-default | Not affected |
SUSE Linux Enterprise Server 15 SP2-LTSS | kernel-source | Not affected |
SUSE Linux Enterprise Server 15 SP3 | kernel-source | Not affected |
SUSE Linux Enterprise Server 15 SP3-LTSS | kernel-default | Not affected |
SUSE Linux Enterprise Server 15 SP3-LTSS | kernel-source | Not affected |
SUSE Linux Enterprise Server 15 SP4 | kernel-source | Not affected |
SUSE Linux Enterprise Server 15 SP4-LTSS | kernel-default | Not affected |
SUSE Linux Enterprise Server 15 SP4-LTSS | kernel-source | Not affected |
SUSE Linux Enterprise Server for SAP Applications 12 SP5 | kernel-default | Not affected |
SUSE Linux Enterprise Server for SAP Applications 12 SP5 | kernel-source | Not affected |
SUSE Linux Enterprise Server for SAP Applications 12 SP5 | kernel-source-azure | Not affected |
SUSE Linux Enterprise Server for SAP Applications 15 SP2 | kernel-default | Not affected |
SUSE Linux Enterprise Server for SAP Applications 15 SP2 | kernel-source | Not affected |
SUSE Linux Enterprise Server for SAP Applications 15 SP3 | kernel-default | Not affected |
SUSE Linux Enterprise Server for SAP Applications 15 SP3 | kernel-source | Not affected |
SUSE Linux Enterprise Server for SAP Applications 15 SP4 | kernel-default | Not affected |
SUSE Linux Enterprise Server for SAP Applications 15 SP4 | kernel-source | Not affected |
Products past their end of life and not receiving proactive updates anymore. | ||
HPE Helion OpenStack 8 | kernel-source | Not affected |
SUSE CaaS Platform 4.0 | kernel-source | Not affected |
SUSE CaaS Platform Toolchain 3 | kernel-source | Not affected |
SUSE Enterprise Storage 6 | kernel-source | Not affected |
SUSE Enterprise Storage 7 | kernel-source | Not affected |
SUSE Enterprise Storage 7.1 | kernel-source | Not affected |
SUSE Linux Enterprise Desktop 11 SP4 | kernel-source | Not affected |
SUSE Linux Enterprise Desktop 12 SP1 | kernel-source | Unsupported |
SUSE Linux Enterprise Desktop 12 SP2 | kernel-source | Not affected |
SUSE Linux Enterprise Desktop 12 SP3 | kernel-source | Not affected |
SUSE Linux Enterprise Desktop 12 SP4 | kernel-source | Not affected |
SUSE Linux Enterprise Desktop 15 | kernel-source | Not affected |
SUSE Linux Enterprise Desktop 15 SP1 | kernel-source | Not affected |
SUSE Linux Enterprise Desktop 15 SP2 | kernel-source | Not affected |
SUSE Linux Enterprise Desktop 15 SP3 | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 15 | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP1 | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP1-ESPOS | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 15 SP1-LTSS | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 15-ESPOS | kernel-source | Not affected |
SUSE Linux Enterprise High Performance Computing 15-LTSS | kernel-source | Not affected |
SUSE Linux Enterprise Micro 5.0 | kernel-default | Not affected |
SUSE Linux Enterprise Module for Basesystem 15 | kernel-source | Not affected |
SUSE Linux Enterprise Module for Basesystem 15 SP1 | kernel-source | Not affected |
SUSE Linux Enterprise Module for Development Tools 15 | kernel-source | Not affected |
SUSE Linux Enterprise Module for Development Tools 15 SP1 | kernel-source | Not affected |
SUSE Linux Enterprise Point of Sale 12 SP2-CLIENT | kernel-source | Not affected |
SUSE Linux Enterprise Real Time 12 SP5 | kernel-source-rt | Not affected |
SUSE Linux Enterprise Real Time 15 SP2 | kernel-source | Not affected |
SUSE Linux Enterprise Real Time 15 SP3 | kernel-source | Not affected |
SUSE Linux Enterprise Real Time 15 SP3 | kernel-source-rt | Not affected |
SUSE Linux Enterprise Real Time 15 SP4 | kernel-source | Not affected |
SUSE Linux Enterprise Real Time 15 SP4 | kernel-source-rt | Not affected |
SUSE Linux Enterprise Server 11 SP4 | kernel-source | Not affected |
SUSE Linux Enterprise Server 11 SP4 LTSS | kernel-default | Not affected |
SUSE Linux Enterprise Server 11 SP4 LTSS | kernel-source | Not affected |
SUSE Linux Enterprise Server 11 SP4-LTSS | kernel-source | Not affected |
SUSE Linux Enterprise Server 12 SP1 | kernel-source | Unsupported |
SUSE Linux Enterprise Server 12 SP1-LTSS | kernel-source | Unsupported |
SUSE Linux Enterprise Server 12 SP2 | kernel-source | Not affected |
SUSE Linux Enterprise Server 12 SP2-BCL | kernel-source | Not affected |
SUSE Linux Enterprise Server 12 SP2-ESPOS | kernel-source | Not affected |
SUSE Linux Enterprise Server 12 SP2-LTSS | kernel-default | Not affected |
SUSE Linux Enterprise Server 12 SP2-LTSS | kernel-source | Not affected |
SUSE Linux Enterprise Server 12 SP3 | kernel-source | Not affected |
SUSE Linux Enterprise Server 12 SP3-BCL | kernel-source | Not affected |
SUSE Linux Enterprise Server 12 SP3-ESPOS | kernel-source | Not affected |
SUSE Linux Enterprise Server 12 SP3-LTSS | kernel-source | Not affected |
SUSE Linux Enterprise Server 12 SP4 | kernel-source | Not affected |
SUSE Linux Enterprise Server 12 SP4-ESPOS | kernel-source | Not affected |
SUSE Linux Enterprise Server 12 SP4-LTSS | kernel-default | Not affected |
SUSE Linux Enterprise Server 12 SP4-LTSS | kernel-source | Not affected |
SUSE Linux Enterprise Server 15 | kernel-source | Not affected |
SUSE Linux Enterprise Server 15 SP1 | kernel-source | Not affected |
SUSE Linux Enterprise Server 15 SP1-BCL | kernel-source | Not affected |
SUSE Linux Enterprise Server 15 SP1-LTSS | kernel-default | Not affected |
SUSE Linux Enterprise Server 15 SP1-LTSS | kernel-source | Not affected |
SUSE Linux Enterprise Server 15 SP2-BCL | kernel-source | Not affected |
SUSE Linux Enterprise Server 15 SP3-BCL | kernel-source | Not affected |
SUSE Linux Enterprise Server 15-LTSS | kernel-default | Not affected |
SUSE Linux Enterprise Server 15-LTSS | kernel-source | Not affected |
SUSE Linux Enterprise Server for Raspberry Pi 12 SP2 | kernel-source | Not affected |
SUSE Linux Enterprise Server for SAP Applications 12 SP1 | kernel-source | Unsupported |
SUSE Linux Enterprise Server for SAP Applications 12 SP2 | kernel-source | Not affected |
SUSE Linux Enterprise Server for SAP Applications 12 SP3 | kernel-source | Not affected |
SUSE Linux Enterprise Server for SAP Applications 12 SP4 | kernel-source | Not affected |
SUSE Linux Enterprise Server for SAP Applications 15 | kernel-source | Not affected |
SUSE Linux Enterprise Server for SAP Applications 15 SP1 | kernel-source | Not affected |
SUSE Manager Proxy 4.0 | kernel-source | Not affected |
SUSE Manager Proxy 4.1 | kernel-source | Not affected |
SUSE Manager Proxy 4.2 | kernel-source | Not affected |
SUSE Manager Retail Branch Server 4.0 | kernel-source | Not affected |
SUSE Manager Retail Branch Server 4.1 | kernel-source | Not affected |
SUSE Manager Retail Branch Server 4.2 | kernel-source | Not affected |
SUSE Manager Server 4.0 | kernel-source | Not affected |
SUSE Manager Server 4.1 | kernel-source | Not affected |
SUSE Manager Server 4.2 | kernel-source | Not affected |
SUSE OpenStack Cloud 7 | kernel-source | Not affected |
SUSE OpenStack Cloud 8 | kernel-source | Not affected |
SUSE OpenStack Cloud 9 | kernel-source | Not affected |
SUSE OpenStack Cloud Crowbar 8 | kernel-source | Not affected |
SUSE OpenStack Cloud Crowbar 9 | kernel-source | Not affected |
SUSE Real Time Module 15 SP3 | kernel-source-rt | Not affected |
SUSE Real Time Module 15 SP4 | kernel-source-rt | Not affected |
openSUSE Leap 15.3 | kernel-source | Not affected |
openSUSE Leap 15.3 | kernel-source-rt | Not affected |
openSUSE Leap 15.4 | kernel-source | Not affected |
openSUSE Leap 15.4 | kernel-source-azure | Unsupported |
openSUSE Leap 15.4 | kernel-source-rt | Not affected |
Products at an unknown state of their lifecycle. | ||
SUSE Linux Enterprise Server 12 SP5 LTSS Extended Security | kernel-source | Not affected |
SUSE Linux Enterprise Server 12 SP5 LTSS Extended Security | kernel-source-azure | Not affected |
SUSE Timeline for this CVE
CVE page created: Fri Nov 8 08:00:19 2024CVE page last modified: Tue Nov 12 15:16:52 2024