Raw scan report

Brainlayer — the complete, unedited output of the deterministic mcptrustchecker engine v1.9.0, scanned . Every finding, capability tag and score component below is exactly what the engine produced — no AI, no post-processing.

← Back to the scan page
{
  "tool": {
    "name": "mcptrustchecker",
    "version": "1.9.0",
    "methodologyVersion": "mcptrustchecker-1.9"
  },
  "target": {
    "id": "brainlayer",
    "source": {
      "kind": "package",
      "origin": "brainlayer"
    },
    "server": {
      "name": "brainlayer"
    }
  },
  "grade": "A",
  "score": {
    "score": 93,
    "threatScore": 100,
    "grade": "A",
    "band": "A",
    "categorySubtotals": {
      "injection": 0,
      "exfiltration": 0,
      "permissions": 0,
      "supply-chain": 0,
      "network": 0,
      "hygiene": 0
    },
    "vector": [
      {
        "kind": "client",
        "term": "capability-exposure",
        "level": "high",
        "label": "capability blast radius (high) — client exposure if the model is manipulated",
        "appliedPenalty": 6
      },
      {
        "kind": "client",
        "term": "verification-discount",
        "level": "repo",
        "label": "publisher verification (public source) — no provenance, but the source is public and inspectable",
        "appliedPenalty": 1
      },
      {
        "kind": "client",
        "term": "coverage-honesty",
        "level": "source",
        "label": "inspection depth (source) — how much of the target the scan could see",
        "appliedPenalty": 0
      }
    ],
    "gatesFired": [],
    "methodologyVersion": "mcptrustchecker-1.9"
  },
  "capability": {
    "level": "high",
    "reasons": [
      "can send data / act on an external service",
      "can execute shell commands or code"
    ],
    "tags": [
      "code-exec",
      "external-sink"
    ]
  },
  "coverage": {
    "level": "source",
    "inputs": {
      "toolSurface": true,
      "implementationSource": true,
      "packageMetadata": true,
      "liveTransport": false
    },
    "caveats": [
      "Tools were statically extracted from the published source (13 recovered), not enumerated from a running server. Tool-poisoning, Unicode-smuggling, capability and toxic-flow analysis ran on this inferred surface, but a mis-parsed registration could be missed or mis-attributed, so tool-derived findings are capped below “confirmed”. To grade the real runtime surface, scan the running server: --command \"npx -y <package>\"."
    ]
  },
  "findings": [
    {
      "ruleId": "MTC-SRC-001",
      "title": "Dynamic code execution in server code (src/brainlayer/content_class.py)",
      "category": "permissions",
      "severity": "high",
      "confidence": "strong",
      "description": "In the server's implementation (`src/brainlayer/content_class.py:57`): Evaluating strings as code is the most direct RCE primitive; if any tool input reaches it, the server executes attacker-chosen code. This is read from the code itself — not from the tool description — so a poisoned server cannot hide it behind honest-looking metadata.",
      "remediation": "Review this call path: confirm it never receives unsanitized tool input, constrain it, or remove it. Treat a server whose code reaches these sinks as high-capability regardless of what its tools claim.",
      "location": {
        "kind": "server",
        "name": "src/brainlayer/content_class.py"
      },
      "evidence": "quality bench(?:mark)?|eval (?:final )?results)\\b\" r\")\", re.IGNORECASE | re.DOTALL, ) _PERSONAL_RE = re.compile",
      "owasp": "LLM05:2025 Improper Output Handling",
      "data": {
        "rule": "MTC-SRC-001",
        "file": "src/brainlayer/content_class.py",
        "line": 57,
        "nonRuntime": false
      }
    },
    {
      "ruleId": "MTC-SRC-002",
      "title": "Shell/command execution in server code (src/brainlayer/backup_daily.py)",
      "category": "permissions",
      "severity": "high",
      "confidence": "strong",
      "description": "In the server's implementation (`src/brainlayer/backup_daily.py:543`): Spawning a shell/process is command-execution capability; with unsanitized tool input it is command injection / RCE. This is read from the code itself — not from the tool description — so a poisoned server cannot hide it behind honest-looking metadata.",
      "remediation": "Review this call path: confirm it never receives unsanitized tool input, constrain it, or remove it. Treat a server whose code reaches these sinks as high-capability regardless of what its tools claim.",
      "location": {
        "kind": "server",
        "name": "src/brainlayer/backup_daily.py"
      },
      "evidence": "ath: Path) -> None: subprocess.run([\"gunzip\", \"-t\", str(path)], check=True, capture_output=True, text=True) def _d",
      "owasp": "LLM05:2025 Improper Output Handling",
      "data": {
        "rule": "MTC-SRC-002",
        "file": "src/brainlayer/backup_daily.py",
        "line": 543,
        "nonRuntime": false
      }
    },
    {
      "ruleId": "MTC-SRC-002",
      "title": "Shell/command execution in server code (src/brainlayer/cli/__init__.py)",
      "category": "permissions",
      "severity": "high",
      "confidence": "strong",
      "description": "In the server's implementation (`src/brainlayer/cli/__init__.py:88`): Spawning a shell/process is command-execution capability; with unsanitized tool input it is command injection / RCE. This is read from the code itself — not from the tool description — so a poisoned server cannot hide it behind honest-looking metadata.",
      "remediation": "Review this call path: confirm it never receives unsanitized tool input, constrain it, or remove it. Treat a server whose code reaches these sinks as high-capability regardless of what its tools claim.",
      "location": {
        "kind": "server",
        "name": "src/brainlayer/cli/__init__.py"
      },
      "evidence": "cess[str]: result = subprocess.run(args, text=True, capture_output=True, check=False) if result.returncode != 0",
      "owasp": "LLM05:2025 Improper Output Handling",
      "data": {
        "rule": "MTC-SRC-002",
        "file": "src/brainlayer/cli/__init__.py",
        "line": 88,
        "nonRuntime": false
      }
    },
    {
      "ruleId": "MTC-SRC-002",
      "title": "Shell/command execution in server code (src/brainlayer/cli/wizard.py)",
      "category": "permissions",
      "severity": "high",
      "confidence": "strong",
      "description": "In the server's implementation (`src/brainlayer/cli/wizard.py:148`): Spawning a shell/process is command-execution capability; with unsanitized tool input it is command injection / RCE. This is read from the code itself — not from the tool description — so a poisoned server cannot hide it behind honest-looking metadata.",
      "remediation": "Review this call path: confirm it never receives unsanitized tool input, constrain it, or remove it. Treat a server whose code reaches these sinks as high-capability regardless of what its tools claim.",
      "location": {
        "kind": "server",
        "name": "src/brainlayer/cli/wizard.py"
      },
      "evidence": "y: result = subprocess.run([\"ollama\", \"list\"], capture_output=True, text=True, timeout=5) env[\"o",
      "owasp": "LLM05:2025 Improper Output Handling",
      "data": {
        "rule": "MTC-SRC-002",
        "file": "src/brainlayer/cli/wizard.py",
        "line": 148,
        "nonRuntime": false
      }
    },
    {
      "ruleId": "MTC-SRC-002",
      "title": "Shell/command execution in server code (src/brainlayer/config.py)",
      "category": "permissions",
      "severity": "high",
      "confidence": "strong",
      "description": "In the server's implementation (`src/brainlayer/config.py:77`): Spawning a shell/process is command-execution capability; with unsanitized tool input it is command injection / RCE. This is read from the code itself — not from the tool description — so a poisoned server cannot hide it behind honest-looking metadata.",
      "remediation": "Review this call path: confirm it never receives unsanitized tool input, constrain it, or remove it. Treat a server whose code reaches these sinks as high-capability regardless of what its tools claim.",
      "location": {
        "kind": "server",
        "name": "src/brainlayer/config.py"
      },
      "evidence": "try: result = subprocess.run( [\"op\", \"read\", args[2]], capture_output=True,",
      "owasp": "LLM05:2025 Improper Output Handling",
      "data": {
        "rule": "MTC-SRC-002",
        "file": "src/brainlayer/config.py",
        "line": 77,
        "nonRuntime": false
      }
    },
    {
      "ruleId": "MTC-SRC-002",
      "title": "Shell/command execution in server code (src/brainlayer/deploy_drift.py)",
      "category": "permissions",
      "severity": "high",
      "confidence": "strong",
      "description": "In the server's implementation (`src/brainlayer/deploy_drift.py:79`): Spawning a shell/process is command-execution capability; with unsanitized tool input it is command injection / RCE. This is read from the code itself — not from the tool description — so a poisoned server cannot hide it behind honest-looking metadata.",
      "remediation": "Review this call path: confirm it never receives unsanitized tool input, constrain it, or remove it. Treat a server whose code reaches these sinks as high-capability regardless of what its tools claim.",
      "location": {
        "kind": "server",
        "name": "src/brainlayer/deploy_drift.py"
      },
      "evidence": "try: result = subprocess.run( [\"git\", \"-C\", str(repo_root.expanduser()), *args], text=",
      "owasp": "LLM05:2025 Improper Output Handling",
      "data": {
        "rule": "MTC-SRC-002",
        "file": "src/brainlayer/deploy_drift.py",
        "line": 79,
        "nonRuntime": false
      }
    },
    {
      "ruleId": "MTC-SRC-002",
      "title": "Shell/command execution in server code (src/brainlayer/fallback_replay.py)",
      "category": "permissions",
      "severity": "high",
      "confidence": "strong",
      "description": "In the server's implementation (`src/brainlayer/fallback_replay.py:507`): Spawning a shell/process is command-execution capability; with unsanitized tool input it is command injection / RCE. This is read from the code itself — not from the tool description — so a poisoned server cannot hide it behind honest-looking metadata.",
      "remediation": "Review this call path: confirm it never receives unsanitized tool input, constrain it, or remove it. Treat a server whose code reaches these sinks as high-capability regardless of what its tools claim.",
      "location": {
        "kind": "server",
        "name": "src/brainlayer/fallback_replay.py"
      },
      "evidence": "try: output = subprocess.check_output( [\"git\", \"-C\", str(path.parent), \"rev-parse\", \"--show-toplev",
      "owasp": "LLM05:2025 Improper Output Handling",
      "data": {
        "rule": "MTC-SRC-002",
        "file": "src/brainlayer/fallback_replay.py",
        "line": 507,
        "nonRuntime": false
      }
    },
    {
      "ruleId": "MTC-SRC-002",
      "title": "Shell/command execution in server code (src/brainlayer/git_learning.py)",
      "category": "permissions",
      "severity": "high",
      "confidence": "strong",
      "description": "In the server's implementation (`src/brainlayer/git_learning.py:222`): Spawning a shell/process is command-execution capability; with unsanitized tool input it is command injection / RCE. This is read from the code itself — not from the tool description — so a poisoned server cannot hide it behind honest-looking metadata.",
      "remediation": "Review this call path: confirm it never receives unsanitized tool input, constrain it, or remove it. Treat a server whose code reaches these sinks as high-capability regardless of what its tools claim.",
      "location": {
        "kind": "server",
        "name": "src/brainlayer/git_learning.py"
      },
      "evidence": "Any]] = [] hashes = subprocess.run( [\"git\", \"log\", \"--no-merges\", f\"--since={_git_since_arg(since)}\", \"--for",
      "owasp": "LLM05:2025 Improper Output Handling",
      "data": {
        "rule": "MTC-SRC-002",
        "file": "src/brainlayer/git_learning.py",
        "line": 222,
        "nonRuntime": false
      }
    },
    {
      "ruleId": "MTC-SRC-002",
      "title": "Shell/command execution in server code (src/brainlayer/health_check.py)",
      "category": "permissions",
      "severity": "high",
      "confidence": "strong",
      "description": "In the server's implementation (`src/brainlayer/health_check.py:210`): Spawning a shell/process is command-execution capability; with unsanitized tool input it is command injection / RCE. This is read from the code itself — not from the tool description — so a poisoned server cannot hide it behind honest-looking metadata.",
      "remediation": "Review this call path: confirm it never receives unsanitized tool input, constrain it, or remove it. Treat a server whose code reaches these sinks as high-capability regardless of what its tools claim.",
      "location": {
        "kind": "server",
        "name": "src/brainlayer/health_check.py"
      },
      "evidence": "try: result = subprocess.run( [\"ps\", \"axo\", \"pid=,command=\"], text=True, c",
      "owasp": "LLM05:2025 Improper Output Handling",
      "data": {
        "rule": "MTC-SRC-002",
        "file": "src/brainlayer/health_check.py",
        "line": 210,
        "nonRuntime": false
      }
    },
    {
      "ruleId": "MTC-SRC-002",
      "title": "Shell/command execution in server code (src/brainlayer/jsonl_backup.py)",
      "category": "permissions",
      "severity": "high",
      "confidence": "strong",
      "description": "In the server's implementation (`src/brainlayer/jsonl_backup.py:322`): Spawning a shell/process is command-execution capability; with unsanitized tool input it is command injection / RCE. This is read from the code itself — not from the tool description — so a poisoned server cannot hide it behind honest-looking metadata.",
      "remediation": "Review this call path: confirm it never receives unsanitized tool input, constrain it, or remove it. Treat a server whose code reaches these sinks as high-capability regardless of what its tools claim.",
      "location": {
        "kind": "server",
        "name": "src/brainlayer/jsonl_backup.py"
      },
      "evidence": "} try: subprocess.run([\"gunzip\", \"-t\", str(archive_path)], check=True, capture_output=True, text=True)",
      "owasp": "LLM05:2025 Improper Output Handling",
      "data": {
        "rule": "MTC-SRC-002",
        "file": "src/brainlayer/jsonl_backup.py",
        "line": 322,
        "nonRuntime": false
      }
    },
    {
      "ruleId": "MTC-SRC-003",
      "title": "Hardcoded egress to an external endpoint (src/brainlayer/backup_daily.py)",
      "category": "exfiltration",
      "severity": "medium",
      "confidence": "strong",
      "description": "In the server's implementation (`src/brainlayer/backup_daily.py:448`): A hardcoded outbound call to a fixed external host inside server code is a classic exfiltration/telemetry channel — especially paired with reads of local data. This is read from the code itself — not from the tool description — so a poisoned server cannot hide it behind honest-looking metadata.",
      "remediation": "Review this call path: confirm it never receives unsanitized tool input, constrain it, or remove it. Treat a server whose code reaches these sinks as high-capability regardless of what its tools claim.",
      "location": {
        "kind": "server",
        "name": "src/brainlayer/backup_daily.py"
      },
      "evidence": "[folder_id]} init = requests.post( \"https://www.googleapis.com/upload/drive/v3/files?uploadType=resumable&su",
      "owasp": "LLM02:2025 Sensitive Information Disclosure",
      "data": {
        "rule": "MTC-SRC-003",
        "file": "src/brainlayer/backup_daily.py",
        "line": 448,
        "nonRuntime": false
      }
    },
    {
      "ruleId": "MTC-SRC-005",
      "title": "Dynamic module load from a non-literal (src/brainlayer/mcp/__init__.py)",
      "category": "permissions",
      "severity": "medium",
      "confidence": "heuristic",
      "description": "In the server's implementation (`src/brainlayer/mcp/__init__.py:1236`): Loading a module chosen at runtime (from a variable) can pull in and run attacker-influenced code paths. This is read from the code itself — not from the tool description — so a poisoned server cannot hide it behind honest-looking metadata.",
      "remediation": "Review this call path: confirm it never receives unsanitized tool input, constrain it, or remove it. Treat a server whose code reaches these sinks as high-capability regardless of what its tools claim.",
      "location": {
        "kind": "server",
        "name": "src/brainlayer/mcp/__init__.py"
      },
      "evidence": "(upload), poll (check), import (results), run (all-in-one).\", }, \"chunk_",
      "owasp": "LLM05:2025 Improper Output Handling",
      "data": {
        "rule": "MTC-SRC-005",
        "file": "src/brainlayer/mcp/__init__.py",
        "line": 1236,
        "nonRuntime": false
      }
    },
    {
      "ruleId": "MTC-SRC-002",
      "title": "Shell/command execution in packaging/dev tooling (scripts/launchd/throughput-watchdog.py)",
      "category": "permissions",
      "severity": "low",
      "confidence": "heuristic",
      "description": "In a packaging/dev/install script (shipped, but not the server runtime) (`scripts/launchd/throughput-watchdog.py:212`): Spawning a shell/process is command-execution capability; with unsanitized tool input it is command injection / RCE. This is read from the code itself — not from the tool description — so a poisoned server cannot hide it behind honest-looking metadata.",
      "remediation": "Review this call path: confirm it never receives unsanitized tool input, constrain it, or remove it. Treat a server whose code reaches these sinks as high-capability regardless of what its tools claim.",
      "location": {
        "kind": "server",
        "name": "scripts/launchd/throughput-watchdog.py"
      },
      "evidence": "st[Path]: process = subprocess.Popen(command, stdout=subprocess.PIPE, stderr=subprocess.PIPE) if process.stdout",
      "owasp": "LLM05:2025 Improper Output Handling",
      "data": {
        "rule": "MTC-SRC-002",
        "file": "scripts/launchd/throughput-watchdog.py",
        "line": 212,
        "nonRuntime": true
      }
    }
  ],
  "toxicFlows": [],
  "capabilities": [
    {
      "tool": "brain_search",
      "tags": [],
      "reasons": {}
    },
    {
      "tool": "brain_resume",
      "tags": [],
      "reasons": {}
    },
    {
      "tool": "brain_store",
      "tags": [],
      "reasons": {}
    },
    {
      "tool": "brain_get_person",
      "tags": [],
      "reasons": {}
    },
    {
      "tool": "brain_recall",
      "tags": [],
      "reasons": {}
    },
    {
      "tool": "brain_digest",
      "tags": [],
      "reasons": {}
    },
    {
      "tool": "brain_entity",
      "tags": [],
      "reasons": {}
    },
    {
      "tool": "brain_expand",
      "tags": [],
      "reasons": {}
    },
    {
      "tool": "brain_update",
      "tags": [],
      "reasons": {}
    },
    {
      "tool": "brain_tags",
      "tags": [],
      "reasons": {}
    },
    {
      "tool": "brain_supersede",
      "tags": [],
      "reasons": {}
    },
    {
      "tool": "brain_archive",
      "tags": [],
      "reasons": {}
    },
    {
      "tool": "brain_enrich",
      "tags": [],
      "reasons": {}
    }
  ],
  "surfaceDigest": "80e06fdf7233079f7e4a1c6e92304cd0c119c5237700d60f18c7c1c448cb394b",
  "stats": {
    "tools": 13,
    "prompts": 0,
    "resources": 0,
    "findingsBySeverity": {
      "critical": 0,
      "high": 10,
      "medium": 2,
      "low": 1,
      "info": 0
    }
  }
}