{
  "@context": "https://schema.org",
  "@type": [
    "NewsArticle",
    "TechArticle"
  ],
  "id": "ed_ban-the-tool-not-the-use-where-coding-agent-extension-decisions-have-to-live",
  "canonicalUrl": "https://pseedr.com/devtools/ban-the-tool-not-the-use-where-coding-agent-extension-decisions-have-to-live",
  "alternateFormats": {
    "markdown": "https://pseedr.com/devtools/ban-the-tool-not-the-use-where-coding-agent-extension-decisions-have-to-live.md",
    "json": "https://pseedr.com/devtools/ban-the-tool-not-the-use-where-coding-agent-extension-decisions-have-to-live.json"
  },
  "title": "Ban the Tool, Not the Use: Where Coding-Agent Extension Decisions Have to Live",
  "subtitle": "A coding agent read one team's rule against a use of a scraping tool narrowly. Vendor documentation shows why a ban belongs in configuration, and what removing a tool still leaves open.",
  "category": "devtools",
  "datePublished": "2026-11-14T18:44:35.859790+00:00",
  "dateModified": "2026-11-14T18:44:35.859790+00:00",
  "author": "PSEEDR",
  "tags": [],
  "readTimeMinutes": 15,
  "wordCount": 3183,
  "contentTier": "free",
  "isAccessibleForFree": true,
  "editorialFormat": "analysis",
  "qualityFlags": [],
  "sourceCount": 15,
  "newsQualityEligible": true,
  "sourceUrls": [
    "https://modelcontextprotocol.io/specification/2025-11-25/schema",
    "https://modelcontextprotocol.io/specification/2025-11-25/basic/lifecycle",
    "https://code.claude.com/docs/en/mcp",
    "https://code.claude.com/docs/en/plugins/security",
    "https://code.claude.com/docs/en/hooks",
    "https://www.youtube.com/watch?v=y2TmTP7qsvU",
    "https://github.com/obra/superpowers",
    "https://invariantlabs.ai/blog/mcp-security-notification-tool-poisoning-attacks",
    "https://code.claude.com/docs/en/permissions",
    "https://code.claude.com/docs/en/memory",
    "https://code.claude.com/docs/en/managed-mcp",
    "https://www.youtube.com/watch?v=VoHzm1kNbFk",
    "https://github.com/anthropics/claude-code/issues/33106",
    "https://github.com/thedotmack/claude-mem/releases",
    "https://www.testmuai.com/blog/mcp-server-instructions-prompt-injection/"
  ],
  "contentHtml": "<p><strong>A coding agent read one team’s rule against a use of a scraping tool narrowly. Vendor documentation shows why a ban belongs in the configuration that decides which tools exist, and what even removing a tool leaves open.</strong></p>\n<section aria-label=\"Companion video\" style=\"margin:1.5rem 0 2rem\"><h2>Watch the full analysis (15:58)</h2><div style=\"position:relative;width:100%;aspect-ratio:16/9\"><iframe src=\"https://www.youtube.com/embed/_ap7570og1U\" title=\"Ban the Tool, Not the Use: Where Coding-Agent Extension Decisions Have to Live\" style=\"position:absolute;width:100%;height:100%;border:0\" loading=\"lazy\" referrerpolicy=\"strict-origin-when-cross-origin\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" allowfullscreen></iframe></div><p><a href=\"https://www.youtube.com/watch?v=_ap7570og1U\">Watch the full analysis (15:58) on YouTube</a> · <a href=\"https://www.youtube.com/shorts/3mhCphy6qkE\">Watch the Short (0:55)</a></p></section>\n<p>In June 2026, Taimoor Bamazai’s team connected a third-party web-scraping server to the AI coding agent they work with. Bamazai, founder of <a href=\"https://elitesalgorithm.com\" rel=\"nofollow\">Elites Algorithm</a>, described what followed in a written response to PSEEDR. The server’s “own setup text told the agent to treat it as the main tool for web search and scraping.” “We did not expect an extension to rank itself above our setup,” he wrote.</p>\n<p>On 12 June the team ruled that all web and search data had to come through their in-house crawler. The crawler ran under a spending cap, $2 a day on one client project, set in configuration. “A second data source would spend outside that budget,” Bamazai wrote.</p>\n<p>Three days later the agent called the scraper anyway. It used the scraper to read pages on the team’s own site, “because it judged that reading one page was not ‘search data’.” The team rewrote the rule: no calls to that tool at all, and plain page fetches for reading a page. Bamazai’s summary: “We restricted a third-party web-scraping server in our AI coding agent, and the lesson was to ban the tool, not a use of it.”</p>\n<p>The first rule named a category, so the model had to decide on every call whether that call fell inside it, and on one call it decided no. The extension’s setup text, meanwhile, had told the agent to prefer the scraper. PSEEDR’s reading of vendor documentation supports the direction of Bamazai’s lesson and takes it one step further: a decision about a tool holds best in the configuration that decides which tools exist, not in prose the model weighs. Removing a tool still does not reach code an extension runs on its own, other routes to the same capability, or anything an installer has already done.</p>\n<p>Bamazai describes nothing malicious and no data loss; the problem was budget and routing. His account also does not say whether the server’s setup text influenced that particular call, so the case shows the two forces side by side, not one causing the other. PSEEDR has not seen the team’s logs. Bamazai did not name the agent product or the scraping tool, did not say through which channel the setup text arrived, and did not say whether either version of the rule lived in a written instruction file or in the agent’s configuration. He reports no commercial relationship with the scraper’s provider.</p>\n<p>Within those limits, the case raises three questions for engineering managers, platform staff and security reviewers who decide which plugins, hooks, skill packs and tool servers an agent may load. What should a team check before allowing an extension? When the team restricts one, what does a ban on a use miss that a ban on the tool catches? And what does even a tool ban leave open?</p>\n<h2 id=\"extensions-ship-text-not-just-code\">Extensions ship text, not just code</h2>\n<p>The usual pre-install checklist asks about network calls, default permissions and telemetry. Those are questions about what an extension’s code does. Bamazai’s case turns on something else: the words an extension places in front of the model.</p>\n<p>The Model Context Protocol (MCP) provides a slot for those words. In the <a href=\"https://modelcontextprotocol.io/specification/2025-11-25/schema\">2025-11-25 schema</a>, a server’s initialize response carries an optional <code>instructions</code> string that “can be thought of like a ‘hint’ to the model. For example, this information MAY be added to the system prompt.” According to the <a href=\"https://modelcontextprotocol.io/specification/2025-11-25/basic/lifecycle\">lifecycle specification</a>, initialization must be the first exchange between client and server, so this text arrives before the client lists tools or calls any of them.</p>\n<p>Clients decide what to do with it, and at least one documents its choice. Claude Code’s <a href=\"https://code.claude.com/docs/en/mcp\">MCP documentation</a> says that with tool search on, “only tool names and server instructions load at session start.” It advises server authors to use the field to explain “When Claude should search for your tools,” and it cuts server instructions at 4,096 characters (2,048 before v2.1.296). The protocol and a major client therefore invite a server to tell the model when to use it. A server that tells the model to prefer it for web search and scraping is doing what that documentation asks of server authors, whichever channel Bamazai’s server actually used.</p>\n<p>Plugins add more channels. Claude Code’s <a href=\"https://code.claude.com/docs/en/plugins/security\">plugin security page</a> says “a plugin can carry content that runs code on your machine with your user privileges and content that enters Claude’s context as instructions.” Skills, commands and agents “enter Claude’s context as instructions, so they influence what Claude does with the tools it already has.” The <a href=\"https://code.claude.com/docs/en/hooks\">hooks reference</a> adds that for a session-start hook, “Claude Code adds plain-text stdout as context that Claude can see and act on,” and that when a plugin is enabled, its hooks merge with the user’s and the project’s own hooks.</p>\n<p>In early November 2026, that channel was on public display. A <a href=\"https://www.youtube.com/watch?v=y2TmTP7qsvU\">roundup video published on 3 November</a> described the popular Superpowers plugin as skills “plus a hook that tells your agent you have superpowers.” The <a href=\"https://github.com/obra/superpowers\">project’s source</a> confirms the mechanism. Its hook runs when a session starts, is cleared or is compacted, and injects “You have superpowers.” inside <code>EXTREMELY_IMPORTANT</code> tags, followed by the full text of its introductory skill. That skill says: “If you think there is even a 1% chance a skill might apply to what you are doing, you ABSOLUTELY MUST invoke the skill.”</p>\n<p>The same skill also says: “User instructions (…) take precedence over skills, which in turn override default behavior.” Superpowers pushes its own workflow hard, but it does not claim to outrank the user. That matters for how to read Bamazai’s case. The competition is structural rather than adversarial. Each extension speaks for itself, and several extensions can speak at once in the same context. The same video’s creator gave a rough count for another popular bundle, ECC: 71 agents, 314 skills, 98 commands and 27 hooks in one install, and around 30,000 tokens of descriptions if every one were listed, against about 1,400 for Superpowers. He added that the client may trim that list. These are his counts, not PSEEDR measurements.</p>\n<p>Sahiram Babulal, a senior data engineer at <a href=\"https://qubit.capital\" rel=\"nofollow\">Qubit Capital</a>, described the everyday version in a written response to PSEEDR. He works on the technical side of what he called a 60-person firm that matches founders with investors. “A few that we installed print a setup reminder at the start of every session, so the agent carries that text even when the work has nothing to do with them. Probably harmless. You only notice it if you scroll back to the top.” He reports no incident. The point is the channel: text from an extension rides along in every session, whatever the task.</p>\n<p>At the far end of the same channel is deliberate abuse. In April 2025, Invariant Labs <a href=\"https://invariantlabs.ai/blog/mcp-security-notification-tool-poisoning-attacks\">described “tool poisoning”</a>: hidden instructions in a tool description that the model sees and the user typically does not. In one demonstration, a malicious server’s description changed how the agent used a separate, trusted email tool, and the agent sent messages to the attacker even when the user named a different recipient. Bamazai’s case needed no attacker. The channel is the same; hostile intent is optional.</p>\n<h2 id=\"where-the-decision-has-to-live\">Where the decision has to live</h2>\n<p>When Bamazai’s team rewrote its rule, it changed the rule’s shape. The first version named a category of data. The second named a tool. PSEEDR’s reading of why that helps: a rule about a use leaves the tool available and asks the model to classify each call against the rule, while any text the extension placed in the session can argue for the tool. A rule about the tool removes the classification step. But the tool is only truly gone if something other than the model enforces the rule.</p>\n<p>Claude Code’s documentation makes that distinction explicit. Its <a href=\"https://code.claude.com/docs/en/permissions\">permissions page</a> says: “Permission rules are enforced by Claude Code, not by the model. Instructions in your prompt or <code>CLAUDE.md</code> shape what Claude tries to do, but they don’t change what Claude Code allows.” Its <a href=\"https://code.claude.com/docs/en/memory\">memory page</a> says the model treats instruction files “as context, not enforced configuration. To block an action regardless of what Claude decides, use a PreToolUse hook instead.”</p>\n<p>The permissions page also separates two kinds of deny rule. “A bare tool name like <code>Bash</code> removes the tool from Claude’s context entirely, so Claude never sees it.” By contrast, “a scoped rule like <code>Bash(rm *)</code> leaves the tool available and blocks matching calls when Claude attempts them.” For MCP, a rule of the form <code>mcp__&lt;server&gt;__*</code> matches every tool from one server. For a server that a plugin bundles, the server name takes a plugin-scoped form, such as <code>mcp__plugin_my-plugin_database-tools__*</code> in the documentation’s example, so a rule written against the bare server key does not match those tools. Rules are evaluated deny first, then ask, then allow, and a hook that returns “allow” does not override a deny rule.</p>\n<p>To be precise about the evidence: Bamazai did not say where his rewritten rule lives. A rewritten instruction that names the tool is narrower and harder to misread than the original, but it is still text the model weighs. Removing the tool in configuration is a different mechanism, and the argument for it rests on the vendor documentation, not on his report. Other agents have their own controls. Claude Code is used here as one documented implementation, not as the setup either contributor uses.</p>\n<p>One more detail of the rewrite is worth keeping. It did not only forbid the scraper; it named plain page fetches as the approved way to read a page. PSEEDR’s inference is that this half matters too. The need to read a page was legitimate, and a ban that also names a permitted route gives the agent less reason to look for an exception.</p>\n<p>At organization scale, the same split applies to which servers load at all. Claude Code’s <a href=\"https://code.claude.com/docs/en/managed-mcp\">managed MCP page</a> says that by default, “anyone running Claude Code can connect any MCP server they choose,” and that Anthropic “doesn’t security-audit or manage any MCP server.” Administrators can deploy allowlists and denylists, and for a denylist match, “Nothing overrides a denylist match.” Two details catch teams out. A <code>serverName</code> entry “is not a security control,” because the name is a label any user can assign, so enforcement needs entries that match a server’s URL or command. And unless the allowlist is locked to managed settings, a user’s own allowlist merges in and can widen it. The page also warns that a blocked server simply disappears from the user’s view, so teams should tell people what they have blocked.</p>\n<h2 id=\"hooks-get-less-review-and-they-are-also-a-lever\">Hooks get less review, and they are also a lever</h2>\n<p>“Who reviews a hook?” Babulal asked. “Hooks, the small scripts the agent runs around each tool call, get far less attention than plugins.”</p>\n<p>The documentation explains why that gap matters. According to Claude Code’s plugin security page, “command hooks and monitors are shell commands that run with your full user permissions,” and Claude Code runs hooks, monitors and MCP and language servers outside its sandbox. Permission rules cover the tool calls the model makes, not the code a plugin runs by itself. The page also notes that the Will install section of the plugin details pane “shows that a hook exists but not what it runs,” and it tells reviewers to read the plugin’s <code>hooks/hooks.json</code>, <code>.mcp.json</code> and <code>bin/</code> files directly. If auto-update is on for the plugin’s marketplace, the files a reviewer approved can change on disk later. Administrators can use a managed setting, <code>allowManagedHooksOnly</code>, to block user, project and plugin hooks other than those from plugins the organization force-enables.</p>\n<p>The same mechanism is also a control. Since March, Babulal said, one repository his firm’s marketing team runs has had a hook that stops the agent’s browser-control tool from touching one particular website at all. That tool acts inside one person’s Chrome. The logins the site needs live with the team’s own scripts, so the hook sends the agent back to those scripts every time.</p>\n<p>That restriction targets a destination, not a tool, and tool-name rules express it poorly. In Claude Code, for example, settings files skip any MCP permission rule that tries to match a tool’s arguments; argument matching for MCP tools is available only through a command-line flag. A pre-tool-use hook can read the call’s input and block it. A <a href=\"https://www.youtube.com/watch?v=VoHzm1kNbFk\">video explainer published on 31 October 2026</a> about a plugin called context-mode described the same idea from the extension builder’s side: its hooks redirect tool choices, and “routing is enforced by hooks, not left to the model’s mood.” That is the video’s description, which PSEEDR did not check against the project’s code.</p>\n<p>Hooks have limits as enforcement. The hooks reference says that because one of its filtering mechanisms is best-effort, teams should “use the permission system rather than a hook to enforce a hard allow or deny.” A matcher written against a plugin-bundled server’s bare name never fires. And one user <a href=\"https://github.com/anthropics/claude-code/issues/33106\">reported in March 2026</a> that a hook’s deny decision was not enforced for MCP tool calls; an automated bot closed the report for inactivity in April without a maintainer response. That report does not establish a bug, but it is a reason to test that a block actually blocks. A practical division follows: put a flat ban in permission rules, use hooks for conditional checks and redirects, and test both.</p>\n<h2 id=\"what-removing-the-tool-still-does-not-catch\">What removing the tool still does not catch</h2>\n<p>A tool ban answers one question: which tools may the model call? It does not answer what else can reach the network, what the extension’s own processes do, or what an installer has already done.</p>\n<p>The shell is the first gap. Claude Code’s permissions page says a Bash deny rule “covers the invocation Claude usually produces and isn’t a security boundary around the program.” A rule against <code>curl</code> does not stop <code>/usr/bin/curl</code> or the same command wrapped in <code>sh -c</code>. The page adds: “Note that using WebFetch alone doesn’t prevent network access. If Bash is allowed, Claude can still use <code>curl</code>, <code>wget</code>, or other tools to reach any URL.” For network-level limits, the documentation points to sandboxing. Applied to Bamazai’s case, as PSEEDR’s inference: removing the scraper tool stops the model from calling that tool, but on its own it would not stop the agent from reaching the same provider’s API through a shell command if the shell and the network were open. Bamazai reported no such attempt.</p>\n<p>The second gap is code the extension runs for itself. Hooks, monitors and server processes run with the user’s permissions, outside the rules that govern the model’s tool calls. A tool ban says nothing about them. Only removing the extension does.</p>\n<p>The third gap is the install step, and the same early-November week supplied an example. The 3 November roundup video read from the release notes of claude-mem, a memory plugin. In <a href=\"https://github.com/thedotmack/claude-mem/releases\">those notes for v15.8.3</a>, dated 2 November, the project says that the browser setup opened by <code>npx claude-mem install</code> (since v15.2.0) “scanned local agent histories and uploaded the full text of the last 30 days of prompts, with session IDs, project names, folder paths and timestamps, without asking.” The fix makes setup scan locally, then stop and ask, with a consent panel listing what would be sent. The notes also state: “Prompts already uploaded by earlier versions are not removed by this update.” They attribute the behavior to the browser setup and do not describe the plugin install route as affected. The relevance here is structural. According to the notes, that flow belonged to the install step rather than to an agent session, so in PSEEDR’s reading no deny rule, hook or instruction file inside a session would have seen it. A review that starts after installation has already missed it.</p>\n<h2 id=\"a-pre-install-check-built-around-these-failure-modes\">A pre-install check built around these failure modes</h2>\n<p>The table below collects the questions this case and the documentation raise. It is a working list drawn from documented mechanisms and two written accounts, not a standard or a certification.</p>\n<table>\n<colgroup>\n<col style=\"width: 33%\" />\n<col style=\"width: 33%\" />\n<col style=\"width: 33%\" />\n</colgroup>\n<thead>\n<tr>\n<th>Check</th>\n<th>What to look at</th>\n<th>Why it matters</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>What it runs on its own</td>\n<td>Install and setup steps; <code>hooks/hooks.json</code>, <code>.mcp.json</code> and <code>bin/</code>; any monitors or server processes; whether auto-update is on</td>\n<td>This code runs with the user’s permissions, outside permission rules and the sandbox; install steps can act before any session exists</td>\n</tr>\n<tr>\n<td>What text it adds to context</td>\n<td>Server instructions, tool descriptions, session-start output, skills</td>\n<td>The text competes with team guidance. A September 2026 <a href=\"https://www.testmuai.com/blog/mcp-server-instructions-prompt-injection/\">TestMu AI post</a> notes that server instructions arrive before tools are listed, so checks that inspect only tool descriptions miss them</td>\n</tr>\n<tr>\n<td>Which routes it competes with</td>\n<td>Tools that duplicate a capability the team already routes elsewhere; whose budget and credentials a call spends</td>\n<td>Bamazai’s spending cap governed the crawler, not the scraper that claimed the same job</td>\n</tr>\n<tr>\n<td>Where the decision lives</td>\n<td>A configuration rule on the exact tool or server name, including plugin-scoped names, or a written instruction</td>\n<td>Instructions shape what the model tries; configuration decides what exists</td>\n</tr>\n<tr>\n<td>Whether the decision holds</td>\n<td>Start a session and confirm the tool is absent; attempt the blocked call; test hook denials</td>\n<td>A rule written against the wrong name matches nothing; hook enforcement should be verified, not assumed</td>\n</tr>\n<tr>\n<td>What else reaches the same capability</td>\n<td>Shell access, network rules, sandbox settings</td>\n<td>Removing a tool does not remove the network</td>\n</tr>\n<tr>\n<td>Who notices change</td>\n<td>Version pinning, update settings, how users learn what is blocked</td>\n<td>Reviewed files can change on disk; blocked servers can disappear without explanation</td>\n</tr>\n</tbody>\n</table>\n<h2 id=\"the-answer\">The answer</h2>\n<p>A ban on a use leaves the tool in the model’s view and turns every call into a classification question that the model answers, sometimes while the extension’s own text argues for the tool. Bamazai’s agent answered it in a way his team did not intend. A ban on the tool, enforced where the agent’s runtime decides which tools exist, removes the question instead of trusting the model to answer it well. Naming an approved route for the legitimate need, as his team did with plain page fetches, removes the reason to look for an exception.</p>\n<p>Neither form of ban covers what runs outside the model’s tool calls: an extension’s hooks and server processes, a shell with open network access, or a setup flow that has already sent data somewhere. Teams therefore have to decide at two levels: which tools the model may call, and which code and network paths the extension gets at all. The decision belongs in configuration and in the review of what an extension runs, with written instructions explaining it rather than carrying it.</p>\n<p>One question remains open. Once a team has removed a tool from the list, what is the least costly way to close the shell and network side paths without losing the agent’s ability to fetch an ordinary page? Teams that have found an arrangement that holds up in daily use have the experience the documentation does not yet supply.</p>\n",
  "articleImage": {
    "url": "https://storage.googleapis.com/pseedr-content/assets/article-covers/ban-the-tool-not-the-use-where-coding-agent-extension-decisions-have-to-live.d827c0b7.png",
    "width": 1280,
    "height": 720,
    "alt": "A workshop pegboard in blue light with one tool missing from its painted outline, and the headline \"Ban the Tool, Not the Use\" with the PSEEDR wordmark."
  },
  "image": {
    "@type": "ImageObject",
    "url": "https://storage.googleapis.com/pseedr-content/assets/article-covers/ban-the-tool-not-the-use-where-coding-agent-extension-decisions-have-to-live.d827c0b7.png",
    "width": 1280,
    "height": 720,
    "alt": "A workshop pegboard in blue light with one tool missing from its painted outline, and the headline \"Ban the Tool, Not the Use\" with the PSEEDR wordmark."
  }
}
