CVE-2021-35942 json
The wordexp function in the GNU C Library (aka glibc) through 2.33 may crash or read arbitrary memory in parse_param (in posix/wordexp.c) w…
published 2021-07-22 5 y ago modified 2026-10-14 26 d ago also EUVD-2021-22577
- cvss
- 9.1
- version 3.1, CNA
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 2.8%
- EPSS 2.8% chance of exploitation in 30 days, percentile 86%
- public exploits
- 0
- none known
Summary
The wordexp function in the GNU C Library (aka glibc) through 2.33 may crash or read arbitrary memory in parse_param (in posix/wordexp.c) when called with an untrusted, crafted pattern, potentially resulting in a denial of service or disclosure of information. This occurs because atoi was used but strtoul should have been used to ensure correct calculations.
Patch / fix
- Siemens SIMATIC S7-1500 CPU 1518-4 PN/DP MFP V3.1.5
- Siemens SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP V3.1.5
- Siemens SIPLUS S7-1500 CPU 1518-4 PN/DP MFP V3.1.5
- glibc Debian 14, Debian 13, Debian 12 2.31-13
debian advisories DEBIAN-CVE-2021-35942
- glibc Ubuntu 18.04 LTS 2.27-3ubuntu1.5
- glibc Ubuntu 20.04 LTS 2.31-0ubuntu9.7
- glibc Ubuntu Pro 16.04 LTS 2.23-0ubuntu11.3+esm2
ubuntu advisories UBUNTU-CVE-2021-35942
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
- glibc RHEL 8 2.28-164.el8
- nscd RHEL 8 2.28-164.el8
- libnsl RHEL 8 2.28-164.el8
- nss_db RHEL 8 2.28-164.el8
- nss_hesiod RHEL 8 2.28-164.el8
- glibc-utils RHEL 8 2.28-164.el8
- glibc-common RHEL 8 2.28-164.el8
- glibc-benchtests RHEL 8 2.28-164.el8
red hat advisories RHSA-2021:4358
- glibc SLE Module for Development Tools 15 SP3, SLE Module for Basesystem 15 SP3, SLE Micro 5.1 2.31-9.3.2
- glibc SLES for SAP 15 SP1, SLES for SAP 15, SLES 15-LTSS +10 more 2.26-13.59.1
- glibc SLES for SAP 12 SP3, SLES 12 SP3-LTSS, SLES 12 SP3-BCL +4 more 2.22-116.1
- glibc SLES 11 SP4-LTSS, SLE Point of Sale 11 SP3 2.11.3-17.110.37.1
- glibc SLES for SAP 12 SP5, SLES 12 SP5, SLE Software Development Kit 12 SP5 2.22-114.12.1
suse advisories SUSE-SU-2021:3291-1SUSE-SU-2021:3385-1SUSE-SU-2021:3289-1SUSE-SU-2021:14822-1SUSE-SU-2021:2480-1
- glibc openSUSE Tumbleweed 2.38-6.1
- glibc openSUSE Leap 15.3 2.31-9.3.2
- glibc openSUSE Leap 15.2 2.26-lp152.26.9.1
- glibc-testsuite-src openSUSE Leap 15.2 2.26-lp152.26.9.1
opensuse advisories openSUSE-SU-2024:13388-1openSUSE-SU-2021:3291-1openSUSE-SU-2021:1374-1
- nss_hesiod AlmaLinux 8 2.28-164.el8
- glibc-utils AlmaLinux 8 2.28-164.el8
- glibc-benchtests AlmaLinux 8 2.28-164.el8
- compat-libpthread-nonshared AlmaLinux 8 2.28-164.el8
almalinux advisories ALSA-2021:4358
- glibc Rocky Linux 8 2.28-164.el8
rocky linux advisories RLSA-2021:4358
- glibc Arch Linux 2.34-1
arch linux advisories AVG-1621
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-35942 updated cvss 9.1
glibc: Arbitrary read in wordexp()
-
Red Hat Enterprise Linux 6 nscd, glibc, glibc-utils, compat-glibc, glibc-common Red Hat Enterprise Linux 7 nscd, glibc, glibc-utils, compat-glibc, glibc-commonaffected: workaround, no fix planned “Do not use untrusted regular expression input for the wordexp() function.”
-
Red Hat CodeReady Linux Builder (v. 8) nss_hesiod 2.28-164.el8, glibc-benchtests 2.28-164.el8, glibc-debuginfo-common 2.28-164.el8 Red Hat Enterprise Linux AppStream (v. 8) glibc-utils 2.28-164.el8, glibc-debuginfo-common 2.28-164.el8, compat-libpthread-nonshared 2.28-164.el8 Red Hat Enterprise Linux BaseOS (v. 8) nscd 2.28-164.el8, glibc 2.28-164.el8, libnsl 2.28-164.el8, nss_db 2.28-164.el8, glibc-common 2.28-164.el8, glibc-all-langpacks 2.28-164.el8, +3 morefixed: vendor fix “Do not use untrusted regular expression input for the wordexp() function.” RHSA-2021:4358
-
Red Hat Enterprise Linux 9 nscd, glibc, libnsl, nss_db, nss_hesiod, glibc-utils, +6 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
cisa ICSA-23-348-10 updated cvss 9.1
Siemens SIMATIC S7-1500
-
Siemens SIMATIC S7-1500 CPU 1518-4 PN/DP MFP (6ES7518-4AX00-1AB0) >= 3.1.0, < 3.1.5 Siemens SIMATIC S7-1500 CPU 1518-4 PN/DP MFP (6ES7518-4AX00-1AC0) >= 3.1.0, < 3.1.5 Siemens SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP (6ES7518-4FX00-1AB0) >= 3.1.0, < 3.1.5 Siemens SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP (6ES7518-4FX00-1AC0) >= 3.1.0, < 3.1.5 Siemens SIPLUS S7-1500 CPU 1518-4 PN/DP MFP (6AG1518-4AX00-4AC0) >= 3.1.0, < 3.1.5affected: fixed in V3.1.5, mitigation support.industry.siemens.com
Facts from CISA's republication of the vendor's own advisory (CSAF); the linked advisory is the authoritative source. CISA notification · csaf
cisa ICSA-23-166-10 updated cvss 9.1
Siemens SIMATIC S7-1500 TM MFP BIOS
-
Siemens SIMATIC S7-1500 TM MFP - BIOS <V1.3.0affected: fixed in V1.3.0, workaround support.industry.siemens.com
Facts from CISA's republication of the vendor's own advisory (CSAF); the linked advisory is the authoritative source. CISA notification · csaf
CISA SSVC
- Exploitation
- none
- Automatable
- yes
- Technical impact
- partial
- Assessed
- 8 mo ago
Exploit prediction
2.75% chance of exploitation in the next 30 days, higher than 86% of all scored CVEs (FIRST EPSS, 2026-11-08).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CISA ADP | 3.1 | 9.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H |
| NVD | 3.1 | 9.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H |
| CNA | 3.1 | 9.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H |
| NVD | 2.0 | 6.4 | AV:N/AC:L/Au:N/C:P/I:N/A:P |
Affected products
- Siemens SIMATIC S7-1500 CPU 1518-4 PN/DP MFP
- Siemens SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP
- Siemens SIPLUS S7-1500 CPU 1518-4 PN/DP MFP
Classification
References
-
security.gentoo.org
/glsa/202208-24
vendor-advisory, third-party-advisory
-
sourceware.org
/glibc/wiki/Security%20Exceptions
not-applicable
-
sourceware.org
/bugzilla/show_bug.cgi?id=28011
issue-tracking, third-party-advisory
-
sourceware.org
/git/?p=glibc.git%3Ba=commit%3Bh=5adda61f62b77384718b4c0d8336ade8f2b4b35c
broken-link
-
security.netapp.com
/advisory/ntap-20210827-0005/
third-party-advisory
-
lists.debian.org
/debian-lts-announce/2022/10/msg00021.html
mailing-list, third-party-advisory
- cert-portal.siemens.com /productcert/html/ssa-831302.html
- cert-portal.siemens.com /productcert/html/ssa-398330.html
Sources
- CVE List CVE-2021-35942
- NVD CVE-2021-35942
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.