Cargo not respecting umask when extracting crate archives
CVE-2023-38497GHSA-j3xp-wfr4-hx87
What to do
Vendor fix available. Upgrade each affected package to the fixed version on its release line (cargo 0.72.2), redeploy, then verify what is actually installed.
This page has no inventory attached, so it cannot say whether you are affected. A vendor fix is not proof that your deployment is fixed.
Affected packages
crates.io cargo
- Affected
- <= 0.72.1
- Fixed in
- 0.72.2
Sources
- GitHub Advisory Database and maintainer security advisories on GitHub
GitHub-reviewed advisory GHSA-j3xp-wfr4-hx87 lists affected ranges: crates.io cargo >=0 <=0.72.1
VerifiedObserved Structured GitHub Advisory Database record (type=reviewed) from the GitHub REST API.
Severity and exploitation
- Exploitation
- No confirmed exploitation recorded. Patch Next marks exploitation only from CISA KEV.
- CVSS
- 7.9 · CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:N
- EPSS
- CVE-2023-38497: 0.70% estimated exploitation activity in the next 30 days; percentile 53.30 (FIRST EPSS, 2026-11-03). This is a model estimate, not proof of exploitation or customer exposure.
Source description
As published by the source; long descriptions are shortened.
The Rust Security Response WG was notified that Cargo did not respect the umask when extracting crate archives on UNIX-like systems. If the user downloaded a crate containing files writeable by any local user, another local user could exploit this to change the source code compiled and executed by the current user. This vulnerability has been assigned CVE-2023-38497. Overview In UNIX-like systems, each file has three sets of permissions: for the user owning the file, for the group owning the file, and for all other local users. The "[umask][1]" is configured on most systems to limit those permissions during file creation, removing dangerous ones. For example, the default umask on macOS and most Linux distributions only allow the user owning a file to write to it, preventing the group owning it or other local users from doing the same. When a dependency is downloaded by Cargo, its source code has to be extracted on disk to allow the Rust compiler to read as part of the build. To…
Dates and revisions
- Published by the source
- Last modified by the source
- Source last checked
- Revision 1 · created ·
Published from ghsa record GHSA-j3xp-wfr4-hx87
Agent brief
Preview the exact text before you copy it. Commands are read-only suggestions; review them before running anything.
# Patch Next advisory brief: CVE-2023-38497 Advisory: Cargo not respecting umask when extracting crate archives IDs: CVE-2023-38497, GHSA-j3xp-wfr4-hx87 Record: https://patchnext.com/advisories/cve-2023-38497 (revision 1, source checked 26 Oct 2026, 15:37 UTC) Inventory: none attached. This brief comes from a public page and does not say whether any deployment is affected. Severity: High (CVSS 7.9) Exploitation: no confirmed exploitation recorded. Patch Next confirms exploitation only from CISA KEV. Vendor response: Vendor fix available; fixed versions by package: cargo 0.72.2. A vendor fix does not mean a deployment is fixed. ## Affected components - crates.io cargo: affected <= 0.72.1; fixed in 0.72.2 ## Suggested inspection (read-only) - crates.io cargo: check the installed version with your package manager. ## Supported action Upgrade each affected component to a fixed version on its release line. For a transitive dependency, upgrade the parent package or add an override or constraint, then regenerate the lockfile. Redeploy every environment that ran an affected version. ## Required regression checks - Run the test suite and a production build. - Exercise the features that depend on cargo. - Repeat the inspection and confirm that only fixed versions remain installed. ## Rollback considerations - Keep the previous lockfile and deployment artifact. Rolling back reinstates the vulnerable version, so apply any documented mitigation while you fix forward. ## Unresolved questions - Which deployments run an affected version? - Exploitation status can change. Check again before lowering the priority. - Mark the work resolved only after the fixed version is verified in production. ## Sources - Verified: https://github.com/advisories/GHSA-j3xp-wfr4-hx87 (GitHub-reviewed advisory GHSA-j3xp-wfr4-hx87 lists affected ranges: crates.io cargo >=0 <=0.72.1) Commands are suggestions: review each one before running it.
Loading voting…