src/mcp-scanner.ts and src/gateway.ts map directly to OWASP Top 10 for Agentic Applications (2026) categories ASI01–ASI06.
MCP Manifest Pinning (ASI04)
Rug-pull attacks occur when an external MCP server passes initial onboarding review and later mutates its tool description or JSON schema stealthily.
computeToolManifestHash(tool) hashes canonical JSON (canonicalJson) of { serverId, toolName, description, inputSchema } using SHA-256:
Poisoning Rules Enforced by scanMcpToolDefinition
hidden_instruction_tag:<important>,<system>,<instructions>,<override>,<hidden>instruction_override_phrase:"ignore all previous instructions","disregard prior rules", etc.exfiltration_directive: attempts to reference.ssh,id_rsa,aws_secret,.env,credentials,cookies, orprivate keytool_shadowing_directive: instructions telling the model"before calling X ... call/redirect Y"zero_width_obfuscation: invisible Unicode bidirectional/zero-width characters (\u200B–\u200F,\u202A–\u202E,\u2060,\uFEFF)unpinned_mcp_tool/mcp_manifest_rug_pull: absence from allowlist or SHA-256 hash mismatch