agentleFS
bvisiblebvisible/mcp-ssh-manager/skills/ssh-restricted/SKILL.md

ssh-restricted

Skill534 starsChanged 17 days agoMITView on GitHub

What to do when an ssh_* tool refuses to run: security modes (readonly, restricted) and human approval. Use when a command is denied, refused, or seems to hang waiting for something.

The file

We split this skill into the rules it gives an agent

4 rules. About 0 are common, 3 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈3

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Do not look for a way around it: Do not:

    line 38
  2. Distinctive:

    ask the user to disable the mode so you can continue.

    line 43
  3. Very specific:

    When a server is set to destructive or always approval, the engine pauses and asks a human before running.

    line 51
  4. Distinctive:

    If it comes back "Refused by the operator", do not run a variation of the same command hoping it slips through.

    line 55

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

When a server says no

MCP SSH Manager lets an operator constrain what an agent may do, per server. A refusal is the system working, not a bug to route around.

The three answers you can get

"Policy denied: Tool X is disabled (mode: readonly)" — the server is read-only. Mutating tools (ssh_deploy, ssh_upload, ssh_execute_sudo, ssh_backup_restore, ssh_db_import…) are off entirely. Reading still works.

"Policy denied: ... matches built-in destructive pattern" or "does not match the allow patterns" — the server is restricted. The operator listed what may run there, and this is not on the list.

"Refused by the operator" — a human saw the command in the control plane and said no. That is a person, not a rule.

What to do about it

Say what was refused and why, plainly. The operator configured this on purpose; they need to know their agent hit the wall, not that "something went wrong".

Offer the read-only equivalent. Refused systemctl restart nginx? You can still ssh_service_status, ssh_tail the error log, and report what you found along with the exact command a human would need to run. That is usually more useful than the restart would have been.

Do not look for a way around it. Do not:

  • retry the same thing through ssh_execute because the specific tool was blocked — the policy layer covers both;
  • reach for another server that is less constrained to do the same work;
  • ask the user to disable the mode so you can continue. If they want it off, they will say so.

Working around a control someone deliberately put in place is worse than failing the task, because they will believe it held.

Approval, and waiting

When a server is set to destructive or always approval, the engine pauses and asks a human before running. From your side the call simply takes longer — that is expected, and it is what the operator wanted.

If it comes back "Refused by the operator", do not run a variation of the same command hoping it slips through. Report the refusal and ask what they would prefer instead.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.