CVE-2021-4157 json
An out of memory bounds write flaw (1 or 2 bytes of memory) in the Linux kernel NFS subsystem was found in the way users use mirroring (rep…
published 2022-03-25 4 y ago modified 2026-06-17 4 mo ago also EUVD-2021-34025
- cvss
- 8.0
- version 3.1, NVD
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 1.6%
- EPSS 1.6% chance of exploitation in 30 days, percentile 75%
- public exploits
- 0
- none known
Summary
An out of memory bounds write flaw (1 or 2 bytes of memory) in the Linux kernel NFS subsystem was found in the way users use mirroring (replication of files with NFS). A user, having access to the NFS mount, could potentially use this flaw to crash the system or escalate privileges on the system.
Patch / fix
- linux linux_kernel 4.4.269, 4.9.269, 4.14.233, 4.19.191, 5.4.120, 5.10.38, 5.11.22, 5.12.5
- linux Debian 14, Debian 13, Debian 12 5.10.38-1
debian advisories DEBIAN-CVE-2021-4157
- linux Ubuntu 18.04 LTS 4.15.0-151.157
- linux Ubuntu 20.04 LTS 5.4.0-80.90
- linux-aws Ubuntu 18.04 LTS 4.15.0-1109.116
- linux-aws Ubuntu 20.04 LTS 5.4.0-1054.57
- linux-gcp Ubuntu 20.04 LTS 5.4.0-1049.53
- linux-gke Ubuntu 20.04 LTS 5.4.0-1049.52
- linux-kvm Ubuntu 18.04 LTS 4.15.0-1097.99
- linux-kvm Ubuntu 20.04 LTS 5.4.0-1044.46
ubuntu advisories UBUNTU-CVE-2021-4157
Ubuntu security data © Canonical Ltd., from https://github.com/canonical/ubuntu-security-notices via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0
- kernel RHEL 8 4.18.0-372.9.1.el8
- perf RHEL 8 4.18.0-372.9.1.el8
- bpftool RHEL 8 4.18.0-372.9.1.el8
- kernel-core RHEL 8 4.18.0-372.9.1.el8
- kernel-tools RHEL 8 4.18.0-372.9.1.el8
- python3-perf RHEL 8 4.18.0-372.9.1.el8
- kernel-modules RHEL 8 4.18.0-372.9.1.el8
- kernel-zfcpdump RHEL 8 4.18.0-372.9.1.el8
red hat advisories RHSA-2022:1988RHSA-2022:1975
- kernel-syms SLES for SAP 15 SP2, SLES 15 SP2-LTSS, SLES 15 SP2-BCL +6 more 5.3.18-150200.24.126.1
- kernel-source SLES for SAP 15 SP2, SLES 15 SP2-LTSS, SLES 15 SP2-BCL +6 more 5.3.18-150200.24.126.1
- kernel-default SLES for SAP 15 SP2, SLES 15 SP2-LTSS, SLES 15 SP2-BCL +8 more 5.3.18-150200.24.126.1
- kernel-preempt SLES for SAP 15 SP2, SLES 15 SP2-LTSS, SLES 15 SP2-BCL +6 more 5.3.18-150200.24.126.1
- kernel-obs-build SLES for SAP 15 SP2, SLES 15 SP2-LTSS, SLE High Performance Computing 15 SP2-LTSS +3 more 5.3.18-150200.24.126.1
- kernel-default-base SLES for SAP 15 SP2, SLES 15 SP2-LTSS, SLES 15 SP2-BCL +6 more 5.3.18-150200.24.126.1.150200.9.59.2
- kernel-rt SLE Real Time 12 SP5 4.12.14-10.94.1
- kernel-syms-rt SLE Real Time 12 SP5 4.12.14-10.94.1
suse advisories SUSE-SU-2022:2809-1SUSE-SU-2022:2629-1SUSE-SU-2022:2549-1SUSE-SU-2022:2478-1SUSE-SU-2022:2424-2SUSE-SU-2022:2424-1
- kernel-default openSUSE Leap Micro 5.2 5.3.18-150300.59.87.1
- kernel-default-base openSUSE Leap Micro 5.2 5.3.18-150300.59.87.1.150300.18.50.2
opensuse advisories openSUSE-SU-2022:2549-1
- kernel AlmaLinux 8 4.18.0-372.9.1.el8
- perf AlmaLinux 8 4.18.0-372.9.1.el8
- bpftool AlmaLinux 8 4.18.0-372.9.1.el8
- kernel-core AlmaLinux 8 4.18.0-372.9.1.el8
- kernel-tools AlmaLinux 8 4.18.0-372.9.1.el8
- python3-perf AlmaLinux 8 4.18.0-372.9.1.el8
- kernel-modules AlmaLinux 8 4.18.0-372.9.1.el8
- kernel-debug-core AlmaLinux 8 4.18.0-372.9.1.el8
almalinux advisories ALSA-2022:1988
- kernel Rocky Linux 8 4.18.0-372.9.1.el8
- kernel-rt Rocky Linux 8 4.18.0-372.9.1.rt7.166.el8
rocky linux advisories RLSA-2022:1988RLSA-2022:1975
Vendor advisories
What the vendors themselves say about their products: affected, fixed or not affected, and what to do.
red hat product security vex CVE-2021-4157 updated cvss 5.9
kernel: Buffer overwrite in decode_nfs_fh function
-
Red Hat Enterprise Linux 7 perf, kernel, bpftool, kernel-rt, python-perf, kernel-kdump, +8 moreaffected: workaround, no fix planned “Out of support scope”
-
Red Hat Enterprise Linux BaseOS (v. 8) perf 4.18.0-372.9.1.el8, kernel 4.18.0-372.9.1.el8, bpftool 4.18.0-372.9.1.el8, kernel-core 4.18.0-372.9.1.el8, kernel-tools 4.18.0-372.9.1.el8, python3-perf 4.18.0-372.9.1.el8, +15 more Red Hat Enterprise Linux CRB (v. 8) kernel-debuginfo-common-x86_64 4.18.0-372.9.1.el8, kernel-debuginfo-common-aarch64 4.18.0-372.9.1.el8, kernel-debuginfo-common-ppc64le 4.18.0-372.9.1.el8fixed: vendor fix RHSA-2022:1988
-
Red Hat Enterprise Linux NFV (v. 8) kernel-rt 4.18.0-372.9.1.rt7.166.el8, kernel-rt-kvm 4.18.0-372.9.1.rt7.166.el8, kernel-rt-core 4.18.0-372.9.1.rt7.166.el8, kernel-rt-modules 4.18.0-372.9.1.rt7.166.el8, kernel-rt-debug-kvm 4.18.0-372.9.1.rt7.166.el8, kernel-rt-debug-core 4.18.0-372.9.1.rt7.166.el8, +4 more Red Hat Enterprise Linux RT (v. 8) kernel-rt 4.18.0-372.9.1.rt7.166.el8, kernel-rt-core 4.18.0-372.9.1.rt7.166.el8, kernel-rt-modules 4.18.0-372.9.1.rt7.166.el8, kernel-rt-debug-core 4.18.0-372.9.1.rt7.166.el8, kernel-rt-debug-modules 4.18.0-372.9.1.rt7.166.el8, kernel-rt-modules-extra 4.18.0-372.9.1.rt7.166.el8, +2 morefixed: vendor fix RHSA-2022:1975
-
Red Hat Enterprise Linux 6 perf, kernel, python-perf, kernel-kdump, kernel-firmware, kernel-bootwrapper, +1 more Red Hat Enterprise Linux 9 rv, perf, rtla, kernel, bpftool, libperf, +82 morenot affected: vulnerable code not present
Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf
Exploit prediction
1.58% chance of exploitation in the next 30 days, higher than 75% of all scored CVEs (FIRST EPSS, 2026-11-08).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| NVD | 3.1 | 8.0 | CVSS:3.1/AV:A/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H |
| NVD | 2.0 | 7.4 | AV:A/AC:M/Au:S/C:C/I:C/A:C |
Affected products
- n/a kernel
Classification
- Weakness
-
- CWE-119 Improper Restriction of Operations within the Bounds of a Memory Buffer
- Technology feeds
References
-
bugzilla.redhat.com
/show_bug.cgi?id=2034342
issue-tracking, third-party-advisory
- lore.kernel.org /lkml/20210517140244.822185482%40linuxfoundation.org/
-
oracle.com
/security-alerts/cpujul2022.html
third-party-advisory
-
security.netapp.com
/advisory/ntap-20220602-0007/
third-party-advisory
Sources
- CVE List CVE-2021-4157
- NVD CVE-2021-4157
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.