OS Command Injection in github.com/sonirico/mcp-shell (CVE-2026-55580)
Summary
OS command injection in github.com/sonirico/mcp-shell (CVE-2026-55580). Risk of unauthorized operations or information disclosure. Exploitable via config.go. Mitigation: upgrade to 0.6.0 or later.
Original description
The description as published by the source.
mcp-shellat commit17ac0eef5c9a5a42b8fb132d3d034973d55a5433` has two issues that together mean neither the default deploy path nor the recommended "secure mode" delivers the restriction they're marketed as providing. Filing these together because the two failure modes bracket the full intended audience — the from-source path gets users who skip security config entirely, the Docker path gets users who follow the security.yaml example and believe they're protected.
The first issue is in config.go, line 49:
config := &Config{
Security: SecurityConfig{
Enabled: false,
},
...
}
Security is opt-in. The bare binary ships with Enabled: false, and security.go lines 26–29 make the consequence explicit:
func (v *SecurityValidator) validateCommand(command string) error {
if !v.config.Enabled {
v.logger.Debug().Str("command", command).Msg("Security disabled, allowing command")
return nil
}
main.go lines 35–39 confirm the deployment condition:
configFile := os.Getenv("MCP_SHELL_SEC_CONFIG_FILE")
if configFile != "" {
log.Info().Str("config_file", configFile).Msg("Loading security config")
} else {
log.Info().Msg("No security config file specified, security disabled")
}
The README's from-source install path (lines 22–26) runs git clone ... && make install && mcp-shell with no environment variable and no config file. The MCP client config example block (lines 78–85) passes only `MCP_SHE…
Source: GitHub Security Advisories (Global) NVD GitHub Advisory
Auto-generated summary
Assembled by SecPulse from the source data (CVSS, CWE, affected versions) using templates — no AI involved. Check the original description and references below for exact details.
A vulnerability tracked as CVE-2026-55580 has been found in github.com/sonirico/mcp-shell.
Attackers can target a specific entry point like config.go over the network to misuse the product.
Risk of unauthorized operations or information disclosure.
What to do: upgrade github.com/sonirico/mcp-shell to 0.6.0 or later.
If unsure, ask your IT team or search "github.com/sonirico/mcp-shell CVE-2026-55580" on the vendor's site.
CVE-2026-55580 (github.com/sonirico/mcp-shell) — CWE-78
Attack surface: config.go / security.go / main.go / MCP_SHELL_LOG_LEVEL
Patched: 0.6.0 — apply immediately
Plan: 1) Audit SBOM/dependencies, 2) Stage→prod upgrade, 3) Add WAF/proxy monitoring on affected endpoints, 4) Hunt IOCs in logs.
Refs: see the GHSA / vendor advisory / patched release linked on this page.
OS command injection (CWE-78) exists in github.com/sonirico/mcp-shell. Attackers reach the vulnerable code path via config.go.
Check the vendor advisory for the affected versions of github.com/sonirico/mcp-shell. Attack surface: config.go / security.go / main.go / MCP_SHELL_LOG_LEVEL.
Severity: ?. Risk of unauthorized operations or information disclosure.
Update to 0.6.0.
Until the patch is applied: disable the affected feature, apply WAF rules, or restrict access via network ACLs.
Search webserver/proxy logs for unusual request patterns matching this CVE's known IOCs. Run grep -r 'github.com/sonirico/mcp-shell' . against your dependency files (package-lock.json, requirements.txt, go.sum) to find affected services.
Response actions
Concrete steps and command examples for SOC/SRE teams to execute in order
-
1Identify exposure identify
grep -r 'github.com/sonirico/mcp-shell' . | grep -v node_modulesリポジトリと本番環境の依存ファイル (package-lock.json / requirements.txt / go.sum / Gemfile.lock 等) で
github.com/sonirico/mcp-shellを grep し、稼働しているサービス・バージョンを把握する。 -
2Apply patch patch
Upgrade github.com/sonirico/mcp-shell to 0.6.0ステージング環境で 0.6.0 に上げて回帰テスト → 本番反映。回帰テストはアプリの主要ハッピーパスを含めること。
-
3Post-deployment verification verify
Confirm patched version is live in productionパッチ適用後、ステージングで PoC または同等の悪用パターンを再現して脆弱性が閉じたことを確認。本番ではアクセスログ・WAF でアラート再発が無いか継続監視。
Affected packages
References
- package github.com
- web github.com
- web github.com
- web github.com
- web github.com
- web github.com