XML External Entity Affecting phpoffice/phpexcel package, versions >=0.0.0


Severity

Recommended
0.0
high
0
10

CVSS assessment made by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
0.6% (79th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications

Snyk Learn

Learn about XML External Entity vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-PHP-PHPOFFICEPHPEXCEL-9299815
  • published7 Mar 2025
  • disclosed21 Oct 2019
  • creditDaniel Hoffmann

Introduced: 21 Oct 2019

CVE-2019-12331  (opens in a new tab)
CWE-611  (opens in a new tab)

How to fix?

There is no fixed version for phpoffice/phpexcel.

Overview

Affected versions of this package are vulnerable to XML External Entity. The XmlScanner decodes the sheet1.xml from an .xlsx to UTF-8 if something else than UTF-8 is declared in the header. This was a security measurement to prevent CVE-2018-19277 but the fix is not sufficient. By double-encoding the the XML payload to UTF-7 it is possible to bypass the check for the string <!ENTITY.

CVSS Base Scores

version 3.1