CVE-2021-46921

Aliases:UBUNTU-CVE-2021-46921DEBIAN-CVE-2021-46921
Modified
Published: 27 Feb 2024, 09:36
Last modified:05 Aug 2026, 08:45

Vulnerability Summary

Overall Risk (default)
medium
31/100
CVSS Score
7.8 HIGH
v3.1 (cve.org)
EPSS Score
0.24% LOW
0% probability +0.22%
KEV
Not listed
Ransomware
No reports
Public exploits
None found
Dark Web
Not detected

Timeline

27 Feb 2024, 09:36
Published
Vulnerability first disclosed
05 Aug 2026, 08:45
Last Modified
Vulnerability information updated

Description

In the Linux kernel, the following vulnerability has been resolved: locking/qrwlock: Fix ordering in queued_write_lock_slowpath() While this code is executed with the wait_lock held, a reader can acquire the lock without holding wait_lock. The writer side loops checking the value with the atomic_cond_read_acquire(), but only truly acquires the lock when the compare-and-exchange is completed successfully which isn’t ordered. This exposes the window between the acquire and the cmpxchg to an A-B-A problem which allows reads following the lock acquisition to observe values speculatively before the write lock is truly acquired. We've seen a problem in epoll where the reader does a xchg while holding the read lock, but the writer can see a value change out from under it. Writer | Reader -------------------------------------------------------------------------------- ep_scan_ready_list() | |- write_lock_irq() | |- queued_write_lock_slowpath() | |- atomic_cond_read_acquire() | | read_lock_irqsave(&ep->lock, flags); --> (observes value before unlock) | chain_epi_lockless() | | epi->next = xchg(&ep->ovflist, epi); | | read_unlock_irqrestore(&ep->lock, flags); | | | atomic_cmpxchg_relaxed() | |-- READ_ONCE(ep->ovflist); | A core can order the read of the ovflist ahead of the atomic_cmpxchg_relaxed(). Switching the cmpxchg to use acquire semantics addresses this issue at which point the atomic_cond_read can be switched to use relaxed semantics. [peterz: use try_cmpxchg()]

CVSS Metrics

  • v3.1MEDIUMScore: 5.5CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N
  • v3.1HIGHScore: 7.8CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

EPSS Trends

Current EPSS score: 0.24% Percentile: 15%

Techniques & Countermeasures

  • CWE-668Exposure of Resource to Wrong Sphere

    The product exposes a resource to the wrong control sphere, providing unintended actors with inappropriate access to the resource.

Affected Systems

  • debianlinux

    < 5.10.38-1 | < 5.10.38-1 | < 5.10.38-1 | < 5.10.38-1

  • ubuntulinux

    < 4.15.0-144.148 | < 5.4.0-74.83

  • ubuntulinux-allwinner-5.19

    all

  • ubuntulinux-aws

    < 4.15.0-1101.108 | < 5.4.0-1047.49

  • ubuntulinux-aws-5.0

    all

  • ubuntulinux-aws-5.11

    all

  • ubuntulinux-aws-5.13

    all

  • ubuntulinux-aws-5.19

    all

  • ubuntulinux-aws-5.3

    all

  • ubuntulinux-aws-5.4

    < 5.4.0-1047.49~18.04.1

  • ubuntulinux-aws-5.8

    all

  • ubuntulinux-aws-6.2

    all

  • ubuntulinux-aws-fips

    < 4.15.0-2044.46 | all | < 5.4.0-1069.73+fips2

  • ubuntulinux-aws-hwe

    < 4.15.0-1102.109~16.04.1

  • ubuntulinux-azure

    < 4.15.0-1115.128~14.04.1 | < 4.15.0-1115.128~16.04.1 | all | < 5.4.0-1048.50

  • ubuntulinux-azure-4.15

    < 4.15.0-1115.128

  • ubuntulinux-azure-5.11

    all

  • ubuntulinux-azure-5.13

    all

  • ubuntulinux-azure-5.19

    all

  • ubuntulinux-azure-5.3

    all

  • ubuntulinux-azure-5.4

    < 5.4.0-1048.50~18.04.1

  • ubuntulinux-azure-5.8

    all

  • ubuntulinux-azure-6.2

    all

  • ubuntulinux-azure-edge

    all

  • ubuntulinux-azure-fde

    all

  • ubuntulinux-azure-fde-5.19

    all

  • ubuntulinux-azure-fde-6.2

    all

  • ubuntulinux-azure-fips

    < 4.15.0-2027.30 | all | < 5.4.0-1073.76+fips1

  • ubuntulinux-bluefield

    all | < 5.4.0-1012.15

  • ubuntulinux-fips

    < 4.15.0-1060.68 | all

  • ubuntulinux-gcp

    < 4.15.0-1100.113~16.04.1 | all | < 5.4.0-1044.47

  • ubuntulinux-gcp-4.15

    < 4.15.0-1100.113

  • ubuntulinux-gcp-5.11

    all

  • ubuntulinux-gcp-5.13

    all

  • ubuntulinux-gcp-5.19

    all

  • ubuntulinux-gcp-5.3

    all

  • ubuntulinux-gcp-5.4

    < 5.4.0-1044.47~18.04.2

  • ubuntulinux-gcp-5.8

    all

  • ubuntulinux-gcp-6.2

    all

  • ubuntulinux-gcp-fips

    all | < 5.4.0-1067.71~20.04.1

  • ubuntulinux-gke

    all

  • ubuntulinux-gke-4.15

    all

  • ubuntulinux-gke-5.15

    all

  • ubuntulinux-gke-5.4

    all

  • ubuntulinux-gkeop

    < 5.4.0-1016.17

  • ubuntulinux-gkeop-5.4

    all

  • ubuntulinux-hwe

    < 4.15.0-144.148~16.04.1 | all

  • ubuntulinux-hwe-5.11

    all

  • ubuntulinux-hwe-5.13

    all

  • ubuntulinux-hwe-5.19

    all

Showing first 50 affected entries in server-rendered view.

References (9)