Skip to content

Rule Reference

SEC550lintai-ai-securitystablejsonwarn

MCP config: rm auto-approve

MCP configuration auto-approves `Bash(rm:*)` through `autoApprove`

Provider
lintai-ai-security
Surface
json
Scope
per_file
Tier
stable
Severity
warn
Confidence
high
Detection
structural
Remediation
message_only

Activation Model

Preset Membership

This rule is part of the builtin activation graph through these preset memberships.

Lifecycle

Stable Lifecycle Contract

State

stable_gated

Graduation rationale

Matches exact destructive `rm` auto-approval in MCP client config.

Deterministic signal basis

JsonSignals exact array-item detection for `autoApprove: ["Bash(rm:*)"]` on parsed MCP configuration.

Malicious corpus
mcp-autoapprove-sudo-rm
Benign corpus
mcp-autoapprove-sudo-rm-specific-safe
structured evidence required remediation reviewed
Canonical note

Structural stable rule intended as a high-precision check with deterministic evidence.

Nearby Signals

Related Rules

SEC550 / MCP-AUTOAPPROVE-RM

SEC550 flags MCP configuration when autoApprove includes the exact tool token Bash(rm:*).

Why It Matters

rm is a destructive file-deletion primitive. Auto-approving it weakens the review boundary around irreversible filesystem mutation in MCP clients.

Trigger Shape

  • the file is a detected MCP configuration surface
  • autoApprove is a string array
  • the array contains the exact item Bash(rm:*)

Clean Cases

  • review-gated destructive shell commands
  • narrower non-destructive shell permissions
  • configs without rm in autoApprove

Example Trigger

json
{
  "mcpServers": {
    "demo": {
      "command": "node",
      "args": ["server.js"],
      "autoApprove": ["Bash(rm:*)"]
    }
  }
}

Safer Example

json
{
  "mcpServers": {
    "demo": {
      "command": "node",
      "args": ["server.js"],
      "autoApprove": ["Read(*)"]
    }
  }
}

How To Fix

Remove rm from autoApprove and keep destructive file deletion under explicit user review.