Description
In Gradle before version 7.0, on Unix-like systems, the system temporary directory can be created with open permissions that allow multiple users to create and delete files within it. Gradle builds could be vulnerable to a local privilege escalation from an attacker quickly deleting and recreating files in the system temporary directory. This vulnerability impacted builds using precompiled script plugins written in Kotlin DSL and tests for Gradle plugins written using ProjectBuilder or TestKit. If you are on Windows or modern versions of macOS, you are not vulnerable. If you are on a Unix-like operating system with the "sticky" bit set on your system temporary directory, you are not vulnerable. The problem has been patched and released with Gradle 7.0. As a workaround, on Unix-like operating systems, ensure that the "sticky" bit is set. This only allows the original user (or root) to delete a file. If you are unable to change the permissions of the system temporary directory, you can move the Java temporary directory by setting the System Property `java.io.tmpdir`. The new path needs to limit permissions to the build user only. For additional details refer to the referenced GitHub Security Advisory.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| gradle | gradle | < 7.0 | — |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | gradle | No fix yet | — |
| Debian 13 | gradle | No fix yet | — |
| Debian 12 | gradle | No fix yet | — |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 26.10 | gradle | No fix yet | — |
| Ubuntu 26.04 LTS | gradle | No fix yet | — |
| Ubuntu 25.10 | gradle | No fix yet | — |
| Ubuntu 24.04 LTS | gradle | No fix yet | — |
| Ubuntu 22.04 LTS | gradle | No fix yet | — |
Show 3 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 20.04 LTS | gradle | No fix yet | — |
| Ubuntu 16.04 LTS | gradle | No fix yet | — |
| Ubuntu Pro 18.04 LTS | gradle | No fix yet | — |
SUSE
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| SLES 15 SP4 | gradle | 4.4.1-150200.3.7.1 | SUSE-SU-2023:1867-1 |
| SLES 15 SP3 | gradle | 4.4.1-150200.3.7.1 | SUSE-SU-2023:1867-1 |
| SLES 15 SP2 | gradle | 4.4.1-150200.3.7.1 | SUSE-SU-2023:1867-1 |
Show 7 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| SLES for SAP 15 SP3 | gradle | 4.4.1-150200.3.7.1 | SUSE-SU-2023:1867-1 |
| SLES for SAP 15 SP2 | gradle | 4.4.1-150200.3.7.1 | SUSE-SU-2023:1867-1 |
| SLE Real Time 15 SP3 | gradle | 4.4.1-150200.3.7.1 | SUSE-SU-2023:1867-1 |
| SLE HPC 15 SP3 | gradle | 4.4.1-150200.3.7.1 | SUSE-SU-2023:1867-1 |
| SLE HPC 15 SP2 | gradle | 4.4.1-150200.3.7.1 | SUSE-SU-2023:1867-1 |
| SUSE Enterprise Storage 7.1 | gradle | 4.4.1-150200.3.7.1 | SUSE-SU-2023:1867-1 |
| SUSE Enterprise Storage 7 | gradle | 4.4.1-150200.3.7.1 | SUSE-SU-2023:1867-1 |
openSUSE
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| openSUSE Leap 15.4 | gradle | 4.4.1-150200.3.7.1 | SUSE-SU-2023:1867-1 |
Advisories 1
- SUSE-SU-2023:1867-1 Security update for gradle SUSE / openSUSE Security Updates · Feb 4, 2026