# Composer: Path traversal in package bin field lets dependencies chmod arbitrary host files

Advisory record · `GHSA-gjfg-22fp-rrxx`

- **Identifiers:** `GHSA-gjfg-22fp-rrxx` · `BIT-composer-2026-59946` · `CVE-2026-59946` · `PKSA-q3ht-3g42-rg8f`
- **State:** Confirmed
- **Severity:** CVSS 6.1 Medium
- **Critical:** No
- **Weakness (CWE):** [CWE-22](https://cwe.mitre.org/data/definitions/22.html) · [CWE-732](https://cwe.mitre.org/data/definitions/732.html)
- **Tags:** [Path traversal](https://agentprime.io/advisories/tag/path-traversal.md) · [Broken access control](https://agentprime.io/advisories/tag/access-control.md)
- **Published:** 20 Jul 2026
- **Updated:** 20 Jul 2026
- **Reviewed by a person:** No

Published by the GitHub Advisory Database at 20 Jul 2026, 21:57 UTC. agentprime has not analysed this yet, so whether it affects any app is not known.

## Affected packages

- `composer/composer` (Packagist): affected `>=2.3.0, <2.10.2 || >=1.0.0, <2.2.29`; fixed in `2.10.2`, `2.2.29`

## Machine-written summary

Summary written by Claude Haiku from the source advisory. Not reviewed by a person.

> Composer versions >=1.0.0 before 2.2.29, and 2.3.0 before 2.10.2, are vulnerable. A malicious or compromised package dependency, including a transitive one, can declare a bin entry with ".." path segments so that Composer changes the file mode of an existing file outside the package directory during install or update. The attacker can make restricted files, such as private keys, world-readable, but cannot read or modify their contents. Upgrade to Composer 2.2.29 or 2.10.2; no configuration workaround is given.

Written 3 Nov 2026.

## Not analysed yet

We haven’t published our analysis of this Advisory yet. Once a person has reviewed it, this page will say what’s vulnerable, what has to be true for your app to be affected, and how to check.

## Severity and exploitation

- 6.1 Medium, CVSS 3.1: `CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:L/A:N`, from CNA (GitHub_M)

- **CISA KEV:** Not listed.
- **EPSS:** 0.0014, the 3rd percentile, on 16 Nov 2026: FIRST’s estimate of the chance of exploitation in the next 30 days.

## Timeline

- 1 Jul 2026, 09:31 UTC: [Published by the maintainers as a GitHub repository advisory](https://github.com/composer/composer/security/advisories/GHSA-gjfg-22fp-rrxx)
- 31 Oct 2026, 14:25 UTC: First seen by agentprime
- 31 Oct 2026, 14:25 UTC: [Confirmed by OSV](https://osv.dev/vulnerability/GHSA-gjfg-22fp-rrxx)

## Sources

- [GitHub Advisory Database: GHSA-gjfg-22fp-rrxx](https://github.com/advisories/GHSA-gjfg-22fp-rrxx)
- [OSV: GHSA-gjfg-22fp-rrxx](https://osv.dev/vulnerability/GHSA-gjfg-22fp-rrxx)
- <https://github.com/composer/composer/security/advisories/GHSA-gjfg-22fp-rrxx>
- <https://nvd.nist.gov/vuln/detail/CVE-2026-59946>
- <https://github.com/composer/composer/commit/502c6c4f699802d9cf464728b3e8a95674f919a0>
- <https://github.com/composer/composer/commit/c50b1efd13ebd73f6dca19b31424c5a02bf93cc1>
- <https://github.com/composer/composer>
- <https://github.com/composer/composer/releases/tag/2.10.2>
- <https://github.com/composer/composer/releases/tag/2.2.29>

Facts on this page come from the GitHub Advisory Database (CC-BY 4.0), OSV and the other sources listed, as published. We don’t reproduce full advisory descriptions, which can contain exploit code.

## Check whether this affects you

A Match means an installed version is in the affected range above. Most don’t affect the app; agentprime hasn’t analysed this one yet.

- With the agentprime MCP server (<https://api.agentprime.io/mcp>), ask your agent to check the project: `check_lockfile` sends a lockfile, `check_packages` a list of installed packages, and both return the Matches and the upgrades that clear them. `get_advisory` returns this record. Setup: <https://agentprime.io/mcp.md>
- In a browser: <https://agentprime.io/check/> reads your lockfile in the browser, never uploading it.
- Whether it touches your code, with file and line: the Claude Code plugin, <https://agentprime.io/plugin.md>
- As JSON: <https://api.agentprime.io/v1/advisories/GHSA-gjfg-22fp-rrxx>, or `POST https://api.agentprime.io/v1/match` with your packages (<https://agentprime.io/api.md>)

---

The web page: <https://agentprime.io/advisories/GHSA-gjfg-22fp-rrxx/>. Everything for agents: <https://agentprime.io/llms.txt>.
