medium6.3
CVE-2025-22240
Salt allows arbitrary directory creation or file deletion
Impact
Arbitrary directory creation or file deletion. In the find_file method of the GitFS class, a path is created using os.path.join using unvalidated input from the “tgt_env” variable. This can be exploited by an attacker to delete any file on the Master's process has permissions to.
Affected packages
| Ecosystem | Package | Affected | Fixed in |
|---|---|---|---|
| pip | salt | >= 3007.0rc1, < 3007.4 | 3007.4 |
Weakness classification
References
- NVD record
- CVE.org record
- GitHub advisory
- https://docs.saltproject.io/en/3006/topics/releases/3006.12.html
- https://docs.saltproject.io/en/3007/topics/releases/3007.4.html
- https://github.com/advisories/GHSA-xh32-3m67-qjgf
- https://nvd.nist.gov/vuln/detail/CVE-2025-22240
- https://github.com/saltstack/salt/commit/f7c28ffbf18dbf693a15b1ba9493918de3e88cf3