Skip to main content
Glama

critical_file_monitor

Destructive

Monitor critical system files for unauthorized changes using scan, baseline, and check. Protects against modifications, world-writable files, and over-permissive SSH keys.

Instructions

Monitor critical system files for unauthorized changes. Three actions: 'scan' shows current state + permission issues; 'baseline' saves SHA-256 hashes of all critical files to disk; 'check' compares current state against the saved baseline and reports every modified, added, or removed file. Covers SSH keys, shell profiles, /etc/hosts, sudoers, LaunchAgents (macOS), systemd/passwd/shadow (Linux). Detects world-writable files and overly permissive SSH keys.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
actionYes'scan' — show current state; 'baseline' — save hashes to disk; 'check' — diff against saved baseline
baseline_fileNoPath to baseline JSON file (default: ~/.mcp-guard-baseline.json)
extra_pathsNoComma-separated extra paths to include beyond the defaults
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description goes beyond annotations by explaining that 'baseline' saves SHA-256 hashes to disk (destructive side effect) and that 'check' compares against saved baseline. It also mentions detecting world-writable files and overly permissive SSH keys. However, it does not explicitly state whether the baseline action overwrites existing files or if the tool requires elevated permissions, which would add further transparency.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single paragraph of three sentences that efficiently conveys purpose, actions, and file coverage. It front-loads the core function. While it could be slightly more structured (e.g., list actions), it remains concise and readable without superfluous information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool has no output schema, the description adequately covers the three actions and file scopes. It lacks example output or notes on permissions, but for a file integrity monitor, the core behavior is well-described. The annotations (destructiveHint) are consistent, and no critical information is missing for an agent to use the tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 100% schema coverage, the description adds value by elaborating on the 'action' parameter with example values, providing a default path for 'baseline_file', and explaining that 'extra_paths' are comma-separated and extend defaults. This clarifies usage beyond the schema's short descriptions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly identifies the tool as monitoring critical system files for unauthorized changes, detailing three specific actions (scan, baseline, check) and the types of files covered (SSH keys, shell profiles, /etc/hosts, etc.). This distinguishes it from sibling tools like file_watch or hash_files, which have different scopes or purposes.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explains what each action does but provides no guidance on when to use this tool versus alternatives. It does not mention limitations, prerequisites, or when not to use it. For example, it doesn't clarify if this tool should be used instead of file_watch for real-time monitoring or persistence_scan for persistence detection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/zent7x/mcp-guard'

If you have feedback or need assistance with the MCP directory API, please join our Discord server