Skip to content

security(plugins): an unapproved or revoked MCP server still serves resources (mcp_read) and prompts #680

Closed

Description

@ajianaz

Found in the #594 security audit. Severity: medium. Status: confirmed (failing test against tests/fixtures/mock_mcp.py).

Affected code

  • crates/tole-cli/src/tool_roster.rs:554-563: after register_server_tools (which the plugin gate refused), probe_server_extras(cfg).resources is checked for EVERY configured server and the server is added to mcp_read's list.
  • crates/tole-core/src/mcp.rs McpReadTool is Risk::ReadOnly: no approval, and its result goes into the model context.
  • crates/tole-cli/src/main.rs:2983: /mcp:<server>:<prompt> commands are listed for every configured server, and get_server_prompt injects the server's prompt text into the next user message.
  • Prompts and resources are not part of the manifest hash (plugin_lock.rs manifest_hash covers tools only).

Problem

The rug-pull guard (#599) keeps a refused server's TOOLS out, but the same server still puts server-controlled text in front of the model through resources (no approval at all) and prompts. A revoked server keeps being connected.

Scenario

A server is revoked after it started shipping poisoned descriptions. It still advertises resources; the model is offered mcp_read with that server in its enum and reads file:///... content crafted as instructions, with no approval prompt, in missions and cron too.

Reproduction

Scratch test crates/tole-core/tests/audit_594.rs::a_refused_server_contributes_no_model_visible_text: register_server_tools with an admit that refuses returns no tools, then (as the roster does) probe_server_extras reports resources and one prompt, and McpReadTool::new(vec[server]).execute(...) returns "demo body".

Suggested fix

  • Probe extras only for servers whose tools were admitted (!names.is_empty() after the gate), and filter the /mcp: prompt listing and get_server_prompt through the same gate.
  • Do not connect a revoked server at all (decide on the lock before list_manifest).
  • Extend the manifest hash (or a second hash in the lock) to prompts and resource templates, or document that they are out of the pin.

Activity

  1. added
    bug
    on Nov 13, 2026
  2. added a commit that references this issue on Nov 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions