ADVISORIES

GitHub Advisory Database

GHSA-5vvx-3h34-f3gj

MPXJ: XXE Vulnerability in MerlinReader

Details

Impact

MPXJ used the default configuration when creating a DocumentBuilder instance, which leaves doctype declarations enabled, when parsing the XML content of the ZTIMEINTERVALS column from a Merlin project SQLite file. This would allow a carefully crafted XML payload to read an arbitrary file. However, although an arbitrary file can be read, the way the resulting parsed XML is processed by MPXJ means that the data it contains is unlikely to be available for exfiltration.

Patches

The patch is included in MPXJ 16.4.1

Workarounds

Potential workarounds include:

  • Avoid reading Merlin project files with MPXJ
  • Only accept Merlin project files from trusted sources
  • Preprocess Merlin SQLite databases to strip doctype declarations from the ZTIMEINTERVALS column

Affected packages

EcosystemPackageAffected versions
Mavennet.sf.mpxj:mpxj
From 5.5.5 before 16.4.1 (fixed in 16.4.1)
RubyGemsmpxj
From 5.5.5 before 16.4.1 (fixed in 16.4.1)
NuGetMPXJ.Net
From 5.5.5 before 16.4.1 (fixed in 16.4.1)
NuGetnet.sf.mpxj
From 5.5.5 before 16.4.1 (fixed in 16.4.1)
NuGetnet.sf.mpxj-for-csharp
From 5.5.5 before 16.4.1 (fixed in 16.4.1)
NuGetnet.sf.mpxj-for-vb
From 5.5.5 before 16.4.1 (fixed in 16.4.1)
PyPImpxj
From 5.5.5 before 16.4.1 (fixed in 16.4.1)

References