// For flags

CVE-2021-29429

Information disclosure through temporary directory permissions

Severity Score

5.5
*CVSS v3.1

Exploit Likelihood

*EPSS

Affected Versions

*CPE

Public Exploits

1
*Multiple Sources

Exploited in Wild

-
*KEV

Decision

-
*SSVC
Descriptions

In Gradle before version 7.0, files created with open permissions in the system temporary directory can allow an attacker to access information downloaded by Gradle. Some builds could be vulnerable to a local information disclosure. Remote files accessed through TextResourceFactory are downloaded into the system temporary directory first. Sensitive information contained in these files can be exposed to other local users on the same system. If you do not use the `TextResourceFactory` API, you are not vulnerable. As of Gradle 7.0, uses of the system temporary directory have been moved to the Gradle User Home directory. By default, this directory is restricted to the user running the build. As a workaround, set a more restrictive umask that removes read access to other users. When files are created in the system temporary directory, they will not be accessible to other users. If you are unable to change your system's umask, 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.

En Gradle versiones anteriores a 7.0, los archivos creados con permisos abiertos en el directorio temporal del sistema pueden permitir a un atacante acceder a la información descargada por Gradle. Algunas compilaciones pueden ser vulnerables a una divulgación de información local. Los archivos remotos a los que se accede por medio de TextResourceFactory son descargados primero en el directorio temporal del sistema. Información confidencial contenida en estos archivos pueden ser expuestas a otros usuarios locales en el mismo sistema. Si no usa la API "TextResourceFactory", no es vulnerable. A partir de Gradle versión 7.0, los usos del directorio temporal del sistema han sido movido al directorio Gradle User Home. Por defecto, este directorio está restringido al usuario que ejecuta la compilación. Como solución alternativa, establezca una máscara de usuario más restrictiva que elimine el acceso de lectura a otros usuarios. Cuando se crean archivos en el directorio temporal del sistema, no serán accedidos por otros usuarios. Si no puede cambiar la umask de su sistema, puede mover el directorio temporal de Java al configurar el System Property "java.io.tmpdir". La nueva ruta debe limitar los permisos solo al usuario de la compilación

*Credits: N/A
CVSS Scores
Attack Vector
Local
Attack Complexity
Low
Privileges Required
Low
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
None
Availability
None
Attack Vector
Local
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
Low
Integrity
None
Availability
None
Attack Vector
Local
Attack Complexity
Medium
Authentication
None
Confidentiality
Partial
Integrity
None
Availability
None
* Common Vulnerability Scoring System
SSVC
  • Decision:-
Exploitation
-
Automatable
-
Tech. Impact
-
* Organization's Worst-case Scenario
Timeline
  • 2021-03-30 CVE Reserved
  • 2021-04-12 CVE Published
  • 2023-03-08 EPSS Updated
  • 2024-08-03 CVE Updated
  • 2024-08-03 First Exploit
  • ---------- Exploited in Wild
  • ---------- KEV Due Date
CWE
  • CWE-200: Exposure of Sensitive Information to an Unauthorized Actor
  • CWE-377: Insecure Temporary File
CAPEC
Affected Vendors, Products, and Versions
Vendor Product Version Other Status
Vendor Product Version Other Status <-- --> Vendor Product Version Other Status
Gradle
Search vendor "Gradle"
Gradle
Search vendor "Gradle" for product "Gradle"
< 7.0
Search vendor "Gradle" for product "Gradle" and version " < 7.0"
-
Affected
Quarkus
Search vendor "Quarkus"
Quarkus
Search vendor "Quarkus" for product "Quarkus"
<= 2.2.3
Search vendor "Quarkus" for product "Quarkus" and version " <= 2.2.3"
-
Affected