CVE-2026-86541
published high CVSS 4.0 · 7.2knowns before 0.30.0 Path Traversal via code.replace MCP action
Package status and fixes
| Distro / vendor | Release | Package / product | Publisher status | Fixed build | Source |
|---|---|---|---|---|---|
| knowns-dev | — | knowns0 to < 0.30.0 (affected · semver) · 0.30.0 (unaffected · semver) · Other versions: unaffected | Version-specific | Not stated | VulnCheck |
Description
knowns versions before 0.30.0 contain a path traversal vulnerability in the handleCodeReplace() function that allows attackers to overwrite arbitrary files outside the project root. Attackers can supply absolute paths or relative paths containing directory traversal sequences to write malicious content to sensitive files like shell startup scripts or SSH configuration files.
Related advisories
Vendor advisories explicitly linked to this CVE.
No linked advisories were found for this CVE.
Assessment
CVSS risk assessment and additional context for this vulnerability.
- CVSS version
- 4.0
- Base score
- 7.2 / 10
- Severity
- high
- Provider
- VulnCheck · cna
- Vector string
- CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:L/VI:H/VA:H/SC:N/SI:N/SA:N
Additional Assessments
| Version | Score | Severity | Provider | Vector | Scenarios |
|---|---|---|---|---|---|
| 3.1 | 8.3 | high | VulnCheck · cna | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:H/A:H | — |
Publisher product statements
Version ranges and default statuses as reported by each provider.
| Vendor | Product | Version status | Source |
|---|---|---|---|
| knowns-dev | knowns | 0 to < 0.30.0 (affected · semver)0.30.0 (unaffected · semver)Default: unaffected | VulnCheck · cna |
Weaknesses
1- CWE-22 Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')
References
5- handleCodeReplace resolves and writes the caller-supplied path without containment (v0.29.1) https://github.com/knowns-dev/knowns/blob/v0.29.1/internal/mcp/handlers/code.go#L588-L646
- knowns fix commit a2c98fc5c313 https://github.com/knowns-dev/knowns/commit/a2c98fc5c313463576c9348beeec6a74ddd7333b
- knowns v0.30.0 Release Notes https://github.com/knowns-dev/knowns/releases/tag/v0.30.0
- GitHub Security Advisory (GHSA-f539-xgc6-xw7q) https://github.com/knowns-dev/knowns/security/advisories/GHSA-f539-xgc6-xw7q
- VulnCheck Advisory: knowns before 0.30.0 Path Traversal via code.replace MCP action https://www.vulncheck.com/advisories/knowns-before-0.30.0-path-traversal-via-code-replace-mcp-action
Provider assertions
2VulnCheck · cna
knowns before 0.30.0 Path Traversal via code.replace MCP action
CISA-ADP · adp
CISA ADP Vulnrichment
Provenance
- Schema
- 5.2
- Searchable
- yes
- Content hash
- 3d4c5529f75693bf179a4dd58b794f6475b49c1c1ffffd08e070d8499ccf118f
- Ingested
- 30 Sep 2026, 15:34:33 UTC
- Source record
- Official CVE record