// For flags

NotCVE-2025-0004

Symlink Race in Go os.RemoveAll Allows Privileged File Deletion

Severity Score

7.5
*CVSS v3.1

Exploit Likelihood

*EPSS

Affected Versions

*CPE

Public Exploits

0
*Multiple Sources

Exploited in Wild

-
*KEV

Decision

-
*SSVC
Descriptions

The Go standard library function os.RemoveAll prior to Go 1.21.11 and 1.22.4 performs recursive directory deletion in a manner susceptible to a time-of-check/time-of-use (TOCTOU) race. An attacker able to swap the target directory with a symbolic link during deletion may redirect the traversal to unintended filesystem locations, allowing deletion of arbitrary files or directories. This behavior impacts any Go programs that perform recursive deletes on user-controlled paths without additional safeguards.

Although upstream considers this a hardening fix, this behavior has clear and reproducible security consequences. Assigning a NotCVE helps downstream users understand and mitigate the risk across all Go-based applications, not just Kubernetes.

*Credits: Reported by: Igor Agievich
CVSS Scores
Attack Vector
Local
Attack Complexity
High
Privileges Required
Low
User Interaction
None
Scope
Changed
Confidentiality
None
Integrity
High
Availability
High
* Common Vulnerability Scoring System
SSVC
  • Decision:-
Exploitation
-
Automatable
-
Tech. Impact
-
* Organization's Worst-case Scenario
Timeline
  • 2025-06-28 CVE Reserved
  • 2025-06-30 CVE Published
  • 2025-06-30 CVE Updated
  • 2025-06-30 EPSS Updated
  • ---------- Exploited in Wild
  • ---------- KEV Due Date
  • ---------- First Exploit
CWE
  • CWE-363: Race Condition Enabling Link Following
CAPEC
  • CAPEC-27: Leveraging Race Conditions via Symbolic Links
Affected Vendors, Products, and Versions
Vendor Product Version Other Status
Vendor Product Version Other Status <-- --> Vendor Product Version Other Status
Google
Search vendor "Google"
Go Toolchain
Search vendor "Google" for product "Go Toolchain"
>= 1.21.0 < 1.21.11
Search vendor "Google" for product "Go Toolchain" and version " >= 1.21.0 < 1.21.11"
-
Affected
Google
Search vendor "Google"
Go Toolchain
Search vendor "Google" for product "Go Toolchain"
>= 1.22.0 < 1.22.4
Search vendor "Google" for product "Go Toolchain" and version " >= 1.22.0 < 1.22.4"
-
Affected