CVE-2019-7722: Improper Restriction of XML External Entity Reference in PMD

net.sourceforge.pmd:pmd-core Updated 02 Oct 2025

Summary

14/05/2022
Yes i
High
8.1

CVE-2019-7722: Improper Restriction of XML External Entity Reference in PMD. Affects net.sourceforge.pmd:pmd-core versions < 6.0.0. Fixed in 6.0.0. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

PMD is a static code analysis tool used to identify potential issues in software projects. It processes XML files called rulesets to perform the analysis. The vulnerability in PMD versions 5.8.1 and earlier allows attackers to exploit XML external entities in the ruleset files, leading to information disclosure, denial of service, or request forgery attacks. PMD 6.x is not affected due to a change implemented on September 15, 2017.

Vulnerability Detail

The vulnerability arises from PMD's improper handling of XML external entities in ruleset files. Attackers can manipulate these files, either by directly modifying them or through man-in-the-middle attacks when using remote rulesets. This manipulation can result in various security issues, including the disclosure of sensitive information, denial of service attacks, or the forging of requests.

How To Fix

Minimum fixed version

6.0.0

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

If updating PMD is not immediately feasible, a temporary workaround is to avoid using rulesets from untrusted sources or remote rulesets. By limiting the exposure to potentially malicious rulesets, the risk of exploitation can be reduced.

Conclusion

The vulnerability in PMD versions 5.8.1 and earlier allows attackers to exploit XML external entities in ruleset files, leading to various security risks. To mitigate this vulnerability, it is recommended to update PMD to version 6.0.0 or later. Developers should also be cautious when using rulesets from untrusted sources or remote rulesets. For further support on vulnerability remediation, contact DevNack.com.

See every vulnerability recorded for net.sourceforge.pmd:pmd-core →

Share this vulnerability

FAQ

PMD is a static code analysis tool used to identify potential issues in software projects. It analyzes code and provides feedback on coding standards, potential bugs, and other code quality aspects.

A ruleset in PMD is an XML file that specifies the rules and configurations to be used during the code analysis. It defines the criteria for identifying potential issues in the code.

An attacker can exploit this vulnerability by tampering with the ruleset files used by PMD. This can be done either by directly modifying the files or by performing man-in-the-middle attacks to manipulate remote rulesets.

The potential consequences of this vulnerability include information disclosure, denial of service attacks, and request forgery attacks. Attackers can gain access to sensitive information, disrupt the availability of the system, or manipulate requests to perform unauthorized actions.

No, PMD 6.x is not affected by this vulnerability. The issue was addressed in version 6.0.0, released on September 15, 2017.

Related vulnerabilities

Recent vulnerabilities recorded for net.sourceforge.pmd:pmd-core.

How To Fix

Minimum fixed version

6.0.0

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback