CVE-2025-53103 is a medium-severity (CVSS 5.8) CWE-312 vulnerability in org.junit.platform:junit-platform-reporting. A fix is available for org.junit.platform:junit-platform-reporting — see the affected versions and patch details below.
JUnit OpenTestReportGeneratingListener can leak Git credentials
Exploitation Status
Proof-of-concept exploit code exists
- CISA’s SSVC triage found public proof-of-concept exploit code for this CVE, though no confirmed active exploitation.
Exploitation and automatability from CISA’s SSVC triage for CVE-2025-53103.
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
Where this sits among everything scored
Real-World Exposure
org.junit.platform:junit-platform-reportingReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects Maven packages — download data is not available via public APIs for these ecosystems.
Description
Summary
This vulnerability affects JUnit's support for writing Open Test Reporting XML files which is an opt-in feature of junit-platform-reporting.
If a repository is cloned using a GitHub token or other credentials in its URL, for example:
git clone https://${GH_APP}:${GH_TOKEN}@github.com/example/example.git
The credentials are captured by OpenTestReportGeneratingListener which produces (trimmed for brevity):
<infrastructure>
<git:repository originUrl="https://username:[email protected]/example/example.git" />
</infrastructure>
Details
I think this should be configurable in some way to exclude select git information or exclude it entirely.
PoC
- Clone a repo using a GitHub token as shown above.
- Enable the listener
junit.platform.reporting.open.xml.enabled=true - Observe report captures credentials
Impact
Depending on the level of access of the token, it can be nothing, limited, or everything.
If these test reports are published or stored anywhere public, then there is the possibility that a rouge attacker can steal the token and perform elevated actions by impersonating the user or app.
Resolution
JUnit 5.13.2 and later replace credentials in the URL with ***. Moreover, including any Git metadata in the XML output is now an opt-in feature that can be enabled via the new junit.platform.reporting.open.xml.git.enabled=true configuration parameter but is not included by default.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| ☕Maven | org.junit.platform:junit-platform-reporting | ≥ 5.12.0&&< 5.13.2 | 5.13.2org.junit.platform:junit-platform-reporting:5.13.2 |
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for org.junit.platform:junit-platform-reporting, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update org.junit.platform:junit-platform-reporting to 5.13.2 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2025-53103 is resolved across your whole dependency graph.
Workarounds
If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands.
Fixing This On Your OS
If you run this on a Linux distribution, patch through your package manager against the distro's own security advisory below — it tracks the exact backported fix for your release, which can ship on a different timeline (and sometimes a different severity) than the upstream project.
Mitigation for this issue is either not available or the currently available options do not meet the Red Hat Product Security criteria comprising ease of use and deployment, applicability to widespread installation base or stability.Source: Red Hat security advisory for CVE-2025-53103 (CC BY 4.0)
Frequently Asked Questions
Is CVE-2025-53103 in your dependencies?
Find it across Maven, including transitive dependencies.