CyberSecBulletin
CVE-2022-48858NVD status: Modified

Linux: Concurrent Execution using Shared Resource with Improper Synchronization

CVE-2022-48858 is a high-severity concurrent execution using shared resource with improper synchronization vulnerability in Linux, with a CVSS 3.1 base score of 7.0 out of 10. It can be exploited with local access to the system by an attacker with a low-privileged account, without any action from a user. The record lists versions 1a4017926eeea56c7540cc41b42106746ee8a0ee, f3331bc17449f15832c31823f27573f4c0e13e5f, 7c519f769f555ff7d9d4ccba3497bbb589df360a as the first without the flaw, so updating Linux to one of those releases or later removes the exposure. There is no confirmed exploitation so far. EPSS estimates a 0.18% chance of exploitation within 30 days, which is low compared with other CVEs.

Next patch cycle

High severity with no evidence of exploitation so far.

What to do

  1. Update Linux to 1a4017926eeea56c7540cc41b42106746ee8a0ee or f3331bc17449f15832c31823f27573f4c0e13e5f or 7c519f769f555ff7d9d4ccba3497bbb589df360a or 0401bfb27a91d7bdd74b1635c1aae57cbb128da6, whichever matches your release line, or a later version.
  2. Update Linux Kernel to 5.4.185 or 5.10.106 or 5.15.29 or 5.16.15, whichever matches your release line, or a later version.

Affected products and versions

VendorProductAffected versionsFixed in
LinuxLinux073fff8102062cd675170ceb54d90da22fe7e668 up to, but not including, 1a4017926eeea56c7540cc41b42106746ee8a0ee; 50b2412b7e7862c5af0cbf4b10d93bc5c712d021 up to, but not including, f3331bc17449f15832c31823f27573f4c0e13e5f; 50b2412b7e7862c5af0cbf4b10d93bc5c712d021 up to, but not including, 7c519f769f555ff7d9d4ccba3497bbb589df360a; 50b2412b7e7862c5af0cbf4b10d93bc5c712d021 up to, but not including, 0401bfb27a91d7bdd74b1635c1aae57cbb128da6; 50b2412b7e7862c5af0cbf4b10d93bc5c712d021 up to, but not including, 063bd355595428750803d8736a9bb7c8db67d42d; da87ea137373689dec9d3fafa34a57787320a4b3; 5.4.71 up to, but not including, 5.4.185; 5.8.15 up to, but not including, 5.9; and 1 more ranges1a4017926eeea56c7540cc41b42106746ee8a0ee, f3331bc17449f15832c31823f27573f4c0e13e5f, 7c519f769f555ff7d9d4ccba3497bbb589df360a, 0401bfb27a91d7bdd74b1635c1aae57cbb128da6, 063bd355595428750803d8736a9bb7c8db67d42d, 5.4.185
LinuxLinux Kernelbefore 5.4.185; 5.5 up to, but not including, 5.10.106; 5.11 up to, but not including, 5.15.29; 5.16 up to, but not including, 5.16.155.4.185, 5.10.106, 5.15.29, 5.16.15

Version data comes from the organisation that assigned the CVE. Confirm against the vendor advisory before deciding you are unaffected.

How the severity score breaks down

Attack vector
LocalThe attacker needs local access or must trick a user into running something.
Attack complexity
HighSuccess depends on conditions outside the attacker's control.
Privileges required
LowA basic user account is enough.
User interaction
NoneNo action by a victim is required.
Scope
UnchangedImpact stays within the vulnerable component.
Confidentiality
HighAll data handled by the component can be read.
Integrity
HighData or code can be modified at will.
Availability
HighThe component can be taken down completely.

Vector: CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H. Scored by NVD.

Scoring systemScoreSeverityScored by
CVSS 3.17.0HighCNA
CVSS 3.17.0HighNVD

Official description

In the Linux kernel, the following vulnerability has been resolved: net/mlx5: Fix a race on command flush flow Fix a refcount use after free warning due to a race on command entry. Such race occurs when one of the commands releases its last refcount and frees its index and entry while another process running command flush flow takes refcount to this command entry. The process which handles commands flush may see this command as needed to be flushed if the other process released its refcount but didn't release the index yet. Fix it by adding the needed spin lock. It fixes the following warning trace: refcount_t: addition on 0; use-after-free. WARNING: CPU: 11 PID: 540311 at lib/refcount.c:25 refcount_warn_saturate+0x80/0xe0 ... RIP: 0010:refcount_warn_saturate+0x80/0xe0 ... Call Trace: <TASK> mlx5_cmd_trigger_completions+0x293/0x340 [mlx5_core] mlx5_cmd_flush+0x3a/0xf0 [mlx5_core] enter_error_state+0x44/0x80 [mlx5_core] mlx5_fw_fatal_reporter_err_work+0x37/0xe0 [mlx5_core] process_one_work+0x1be/0x390 worker_thread+0x4d/0x3d0 ? rescuer_thread+0x350/0x350 kthread+0x141/0x160 ? set_kthread_struct+0x40/0x40 ret_from_fork+0x1f/0x30 </TASK>

Source: the CVE record as published by its numbering authority, via NVD and CVE.org.

The underlying weakness: Concurrent Execution using Shared Resource with Improper Synchronization

The product contains a concurrent code sequence that requires temporary, exclusive access to a shared resource, but a timing window exists in which the shared resource can be modified by another code sequence operating concurrently.

How developers prevent this class of flaw

  • In languages that support it, use synchronization primitives. Only wrap these around critical code to minimize the impact on performance.
  • Use thread-safe capabilities such as the data access abstraction in Spring.
  • Minimize the usage of shared resources in order to remove as much complexity as possible from the control flow and to reduce the likelihood of unexpected conditions occurring. Additionally, this will minimize the amount of synchronization necessary and may even help to reduce the likelihood of a denial of service where an attacker may be able to repeatedly trigger a critical section (CWE-400).

More Concurrent Execution using Shared Resource with Improper Synchronization vulnerabilities (CWE-362)

Timeline

  1. CVE record published.
  2. CISA published its SSVC assessment (exploitation: none, automatable: no, technical impact: partial).
  3. Record last changed materially (score, affected products, status or references).

References

Recent Concurrent Execution using Shared Resource with Improper Synchronization vulnerabilities

Spotted an error? Tell us.