Soumettre #856634: mastergo-design mastergo-magic-mcp 0.2.0 Improper Access Controlinformation

Titremastergo-design mastergo-magic-mcp 0.2.0 Improper Access Control
DescriptionA vulnerability was found in mastergo-design/mastergo-magic-mcp. The issue affects the MCP tool mcp__getComponentGenerator and the parameter rootPath. The mcp__getComponentGenerator tool accepts a caller-controlled rootPath and constructs a .mastergo directory under that path using raw string concatenation. The implementation then calls fs.mkdirSync with recursive creation enabled and writes generated component workflow files under the attacker-chosen rootPath. There is no path.resolve-based confinement, no trusted workspace boundary, and no rejection of absolute paths or traversal segments. An MCP client that can invoke this tool may cause the server process to create directories and write project-shaped files under arbitrary process-writable paths. The written files include .mastergo/component-workflow.md, a JSON file derived from a MasterGo API response, and image assets. The content is not fully attacker-controlled, but the write location is controlled by the caller, and missing parent directories may be created automatically. Affected package: @mastergo/magic-mcp Affected tool: mcp__getComponentGenerator Affected parameter: rootPath Affected file: src/tools/get-component-workflow.ts CWE: CWE-22 / CWE-73 / CWE-20 CVSS v3.1: CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N Suggested severity: Medium Suggested remediation: resolve rootPath with realpath and require it to remain inside an operator-approved workspace or explicitly selected project root before creating directories or writing files. Reject absolute paths, traversal attempts, and symlink escapes outside the trusted root.
La source⚠️ https://github.com/mastergo-design/mastergo-magic-mcp/issues/90
Utilisateur Mcfly_Zhang (UID 98877)
Soumission12/06/2026 04:18 (il y a 1 mois)
Modérer14/07/2026 17:40 (1 month later)
StatutAccepté
Entrée VulDB378330 [mastergo-design mastergo-magic-mcp jusqu’à 0.2.0 mcp__getComponentGenerator component-workflow.md execute rootPath directory traversal]
Points20

Are you interested in using VulDB?

Download the whitepaper to learn more about our service!