cdmon-mcp CLAUDE.md

Project instructions for an MCP server and command-line tool that connects to cdmon shared hosting through FTP and phpMyAdmin. FTP transfers files, while phpMyAdmin manages the site's database.

In plain words
What is it for?
Use them when changing this repository, especially its FTP or database code. They explain the project's scope, silent failure cases, rules, and invariants.
Why use it?
They document safety rules for working with a live website, including checks that prevent paths from escaping the site directory and defaults that treat inputs cautiously.

Instructions file

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add instructions/opusprojects/cdmon-mcp/claude-md
Clone the repo
git clone --depth 1 https://github.com/OpusProjects/cdmon-mcp
Per session 2,952 This file is loaded in full into every session.
When invoked 2,952 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.02952 $0.02952
Opus 5 $0.01476 $0.01476
Sonnet 5 $0.00590 $0.00590
Haiku 4.5 $0.00295 $0.00295

Measured 2d ago against content hash a988b23f3a71, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

cdmon-mcp CLAUDE.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

CLAUDE.md · 206 lines

How it starts

The opening of the file, as written. The whole thing — 206 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Project Guidelines

Notes for working in this repo. Everything user-facing lives in docs/ — this file holds only what is easy to get wrong and expensive to discover.

What this is

An MCP server and CLI wrapping two interfaces on cdmon shared hosting: FTP and phpMyAdmin. That is the whole remit. It is not a cdmon API client, not a general FTP tool and not a database GUI. Decline scope that widens it — a tool pointed at a production site earns trust by being small enough to read in one sitting.

The caller may be a language model and the target is someone's live website. Every default is the cautious one, and every input is untrusted.

The three things that fail silently

Most of this codebase fails loudly: a login breaks, a transfer errors. These three do not, and they are where the tests are concentrated.

The path guard (resolveInsideRoot in src/ftp.ts). A weakened check throws nothing — it quietly permits a write or a delete outside the site. Two subtleties, both already fixed and both easy to reintroduce:

  • Normalise the relative path and refuse .. before joining it to the root. Joining first looks equivalent but is not: with a root of /, path.posix.normalize clamps /../x back to /x, so a traversal silently becomes a valid path and acts on a file the caller never named.
  • isInside compares with a trailing separator. Without it a root of /site/web also accepts /site/web-backup, which is a different directory.

The SQL splitter (src/sql.ts). A bad split does not throw; it sends malformed SQL that may partially apply. It is a character-by-character state machine, never split(";"). It has to know about single quotes (including doubled '' and backslash escapes), double quotes, backticks, -- comments (only when whitespace follows — 5--3 is arithmetic), # comments and /* */ blocks. /*!40101 ... */ is executable SQL, not a comment; dropping one changes what a restore does.

Configuration (src/config.ts). A half-configured server starts fine and fails later with a protocol error naming nothing useful. requireAllOrNone refuses a partly specified half. Keep it that way, and keep empty strings treated as absent.

Read the full file on GitHub · 206 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 206 lines · 2,952 tokens per session scan A a988b23f3a71

Subscribe to this mod's changes

cdmon-mcp CLAUDE.md is an instructions file published in the GitHub repository OpusProjects/cdmon-mcp (0 stars, last pushed 3d ago), licensed Apache-2.0. It adds 2,952 tokens to every session, about $0.0148 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.