Skip to main content
MEDIUM

CVE-2021-21707

CVSS v3

5.3

MEDIUM

EPSS Score

25.3 %

exploit probability, as of 2026-10-19

CISA KEV

No

known exploited

Exploitation

—

SSVC status

Get an alert for each new CVE published for php.

Set up CVE WatchFree account · no credit card

Affected and fixed versions

Packages from OSV.dev and products from the vendors' CSAF advisories.

version not verifiedVersions not verified: read as OSV.dev and the vendors publish them, not checked against each vendor's release list.

Packages

  • phpBitnamifrom 7.3.0 · fixed in 7.3.33and 2 other packages
  • apcu-panelAlmaLinux:8all versions · fixed in 5.1.18-1.module_el8.6.0+2750+78feabcband 1 other package
  • libzipAlmaLinux:8all versions · fixed in 1.6.1-1.module_el8.6.0+3239+bedf0508and 1 other package
  • libzip-toolsAlmaLinux:8all versions · fixed in 1.6.1-1.module_el8.6.0+2750+78feabcb
  • phpAlmaLinux:8all versions · fixed in 7.4.30-1.module_el8.7.0+3286+227f3cf0and 26 other packages
  • php-pearAlmaLinux:8all versions · fixed in 1:1.10.13-1.module_el8.6.0+3268+b150a051
  • php-pecl-apcuAlmaLinux:8all versions · fixed in 5.1.18-1.module_el8.6.0+3239+bedf0508
  • php-pecl-rrdAlmaLinux:8all versions · fixed in 2.0.1-1.module_el8.6.0+3239+bedf0508

2 more package ranges on OSV.dev

Vendor advisories

  • CVE-2021-21707 Red Hat Product Security423 products fixed · 101 known affected

    php: Special character breaks path in xml parsing

    php as a component of Red Hat Enterprise Linux 6 · php-bcmath as a component of Red Hat Enterprise Linux 6 · php-cli as a component of Red Hat Enterprise Linux 6

  • ICSA-26-027-02 CISA1 known affected

    Festo Didactic SE MES PC

    Festo Didactic SE MES PC shipped with Windows 10

  • RHSA-2022:7628 Red Hat Product Security301 products fixed

    Red Hat Security Advisory: php:7.4 security, bug fix, and enhancement update

  • RHSA-2022:5491 Red Hat Product Security122 products fixed

    Red Hat Security Advisory: rh-php73-php security and bug fix update

Full record on NVD

Description

In PHP versions 7.3.x below 7.3.33, 7.4.x below 7.4.26 and 8.0.x below 8.0.13, certain XML parsing functions, like simplexml_load_file(), URL-decode the filename passed to them. If that filename contains URL-encoded NUL character, this may cause the function to interpret this as the end of the filename, thus interpreting the filename differently from what the user intended, which may lead it to reading a different file than intended.

Technical details

Published
2021-11-29

Frequently asked questions

What is CVE-2021-21707?

In PHP versions 7.3.x below 7.3.33, 7.4.x below 7.4.26 and 8.0.x below 8.0.13, certain XML parsing functions, like simplexml_load_file(), URL-decode the filename passed to them. If that filename contains URL-encoded NUL character, this may cause the function to interpret this as the end of the filename, thus interpreting the filename differently from what the user intended, which may lead it to reading a different file than intended.

Is CVE-2021-21707 actively exploited?

Active exploitation of CVE-2021-21707 has not been confirmed. Its EPSS score was 25.3% on 2026-10-19, the estimated probability of exploitation in the next 30 days.

What is the CVSS score for CVE-2021-21707?

CVE-2021-21707 has a CVSS v3 base score of 5.3 (MEDIUM severity).

Running php? Hear about its next vulnerability

CVE Watch matches each new CVE to the vendors and products you list (vendor and product, not the version) and puts it in your alerts with its KEV and EPSS status.

Already have an account? Open CVE WatchNo credit card required · No monthly cap on website lookups · 250 API requests/month