Drafting a conformance ruleset for MCP servers
The MCP ecosystem has directories and debuggers but no neutral verifier. A ruleset has to be mechanical enough to be trustworthy and narrow enough that maintainers can act on it in an afternoon.
Conformance half
- Handshake — protocol version present and within the supported set.
- Capability honesty — an advertised capability must not answer method-not-found.
- Schema validity — every tool input schema valid against JSON Schema draft-07 or 2020-12.
- Schema/handler agreement — declared required fields must actually be enforced.
- Description completeness — a tool without a usage sentence is a tool the agent will misuse.
- Error semantics — unknown tool and invalid params return JSON-RPC errors, not success payloads.
- Transport behaviour — no stray non-JSON lines on stdout in stdio mode.
- Determinism — two identical read-only calls return the same structural shape.
Security half
Tool descriptions are prompt surface. Instruction-override phrases, zero-width and bidi characters, unbounded string arguments that accept absolute paths, and list tools with no limit parameter are all visible before execution, which makes them statically checkable.
The rule that decides adoption
A scanner that flags everything is worse than no scanner. Every rule needs a fixture taken from a real server, and the false-positive log has to be published. Trust is the product; the checks are just the mechanism.