CVEfocus › CVE database › CVE-2020-15250

CVE-2020-15250Information disclosure in JUnit4

CVSS 4.4 MediumEPSS 1.7% (higher than 78% of CVEs)Published 2020-10-12Updated 2026-10-07Assigner: GitHub_M

In JUnit4 from version 4.7 and before 4.13.1, the test rule TemporaryFolder contains a local information disclosure vulnerability. On Unix like systems, the system's temporary directory is shared between all users on that system. Because of this, when files and directories are written into this directory they are, by default, readable by other users on that same system. This vulnerability does not allow other users to overwrite the contents of these directories or files. This is purely an information disclosure vulnerability. This vulnerability impacts you if the JUnit tests write sensitive information, like API keys or passwords, into the temporary folder, and the JUnit tests execute in an environment where the OS has other untrusted users. Because certain JDK file system APIs were only added in JDK 1.7, this this fix is dependent upon the version of the JDK you are using. For Java 1.7 and higher users: this vulnerability is fixed in 4.13.1. For Java 1.6 and lower users: no patch is available, you must use the workaround below. If you are unable to patch, or are stuck running on Java 1.6, specifying the `java.io.tmpdir` system environment variable to a directory that is exclusively owned by the executing user will fix this vulnerability. For more information, including an example of vulnerable code, see the referenced GitHub Security Advisory.

CWE-200

What to do

Fixed builds are available from Alpine, Debian, Maven, Ubuntu: see the table below for the fixed version per release.

Red Hat, Ubuntu have not shipped a fix for every release yet.

Is your server affected? One read-only command checks every installed package against this CVE and all others, using each vendor's fixed versions. Get started or get a free API key.

curl -sS "https://api.cvefocus.com/v1/check?format=text" -H "Authorization: Bearer $CVEFOCUS_KEY" \
  -H "Content-Type: text/plain" --data-binary @inventory.txt

Vendor status at a glance

19Fixed
4Fix pending
4Will not fix
8Not affected

Status by vendor and release

From each vendor's own security data and VEX statements. "Fixed" means a fixed build is published for that release.

ReleasePackageStatusFixed versionAdvisory
Ubuntu 26.04junit4Not affected
vulnerable_code_not_present
Ubuntu 25.10junit4Not affected
vulnerable_code_not_present
Ubuntu 24.04junit4Not affected
vulnerable_code_not_present
Ubuntu 22.04junit4Not affected
vulnerable_code_not_present
Ubuntu 20.04junit4Fixed4.12-8ubuntu0.20.04.1UBUNTU-CVE-2020-15250
Ubuntu 18.04junit4Fixed4.12-8~18.04.1UBUNTU-CVE-2020-15250
Ubuntu 16.04junit4Fixed4.12-4ubuntu1.1UBUNTU-CVE-2020-15250
Ubuntu 14.04junit4Fix pendingUBUNTU-CVE-2020-15250
Debian 14junit4Fixed4.13.1-1DEBIAN-CVE-2020-15250
Debian 13junit4Fixed4.13.1-1DEBIAN-CVE-2020-15250
Debian 12junit4Fixed4.13.1-1DEBIAN-CVE-2020-15250
Red Hat Enterprise Linux 8junitFix pending
Fix deferred
Red Hat Enterprise Linux 8junit-javadocFix pending
Fix deferred
Red Hat Enterprise Linux 8junit-manualFix pending
Fix deferred
Red Hat Enterprise Linux 7junitWill not fix
Out of support scope
Red Hat Enterprise Linux 7junit-demoWill not fix
Out of support scope
Red Hat Enterprise Linux 7junit-javadocWill not fix
Out of support scope
Red Hat Enterprise Linux 7junit-manualWill not fix
Out of support scope
Red Hat Enterprise Linux 6junit4Not affected
Red Hat Enterprise Linux 6junit4-demoNot affected
Red Hat Enterprise Linux 6junit4-javadocNot affected
Red Hat Enterprise Linux 6junit4-manualNot affected
Alpine Linux 3.24junitFixed4.13.1-r0ALPINE-CVE-2020-15250
Alpine Linux 3.23junitFixed4.13.1-r0ALPINE-CVE-2020-15250
Alpine Linux 3.22junitFixed4.13.1-r0ALPINE-CVE-2020-15250
Alpine Linux 3.21junitFixed4.13.1-r0ALPINE-CVE-2020-15250
Alpine Linux 3.20junitFixed4.13.1-r0ALPINE-CVE-2020-15250
Alpine Linux 3.19junitFixed4.13.1-r0ALPINE-CVE-2020-15250
Alpine Linux 3.18junitFixed4.13.1-r0ALPINE-CVE-2020-15250
Alpine Linux 3.17junitFixed4.13.1-r0ALPINE-CVE-2020-15250
Alpine Linux 3.16junitFixed4.13.1-r0ALPINE-CVE-2020-15250
Alpine Linux 3.15junitFixed4.13.1-r0ALPINE-CVE-2020-15250
Alpine Linux 3.14junitFixed4.13.1-r0ALPINE-CVE-2020-15250
Alpine Linux 3.13junitFixed4.13.1-r0ALPINE-CVE-2020-15250
Maven libraryjunit:junitFixed4.13.1GHSA-269g-pwp5-87pp

What the vendor says

As published in the CVE record by GitHub_M, the CVE's assigner (usually the vendor). Check the vendor's advisory before acting.

References

About this page

Compiled by CVEfocus from the CVE List, the security data and VEX statements of Ubuntu, Debian, Red Hat, AlmaLinux, Rocky Linux and Microsoft, CISA's Known Exploited Vulnerabilities catalog and FIRST EPSS, refreshed several times a day (data status). Information only; see the disclaimer. Official record: cve.org · NVD.