Skip to main content
Glama
glatinone

Secops Toolkit MCP

by glatinone

scan_repo_root

Scan a repository root for files that shadow common developer commands and symlinks pointing outside the directory. Prevents command hijacking and hidden write-target attacks.

Instructions

Check a repo's top-level directory for files that shadow common developer command names (git.exe, node.exe, npm.cmd, etc.), and the whole tree for symlinks that resolve outside the directory.

Run this before opening a freshly cloned or downloaded repository in an agentic coding tool. On Windows, several tools (Cursor, GitHub Copilot CLI, Gemini CLI, Codex) resolve an unqualified command like git from the current directory before PATH, so a malicious repo shipping its own git.exe at the root runs instead of the real one, before any workspace-trust prompt appears. Severity: critical for git (the confirmed vector), high for shells/interpreters, medium for other common dev tools. Only the top-level directory is checked for this, not subdirectories.

Separately, a symlink anywhere in the tree whose resolved target lies outside this directory is flagged too (the GhostApproval/DuneSlide hidden-write-target pattern: an approval dialog shows a decoy path while the symlink redirects the real write elsewhere, e.g. ~/.ssh/authorized_keys). Critical if the resolved target hits a known sensitive path (SSH/cloud-credential directories, private key files), high otherwise.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior4/5

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

With no annotations provided, the description carries full burden and effectively discloses behavior: it checks top-level for shadowed executables and whole-tree for external symlinks, with severity levels. It does not mention non-destructive nature or auth needs, but these are implied by scanning.

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 well-structured, starting with the purpose and then detailing two distinct checks with rationale. It is relatively long but every sentence adds value, explaining the threat model and severity. Minor trimming possible but justified by complexity.

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

Completeness5/5

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

Given the complexity of two scanning operations, no annotations, and an output schema present (so return values don't need explanation), the description is complete. It covers what is checked, why, severity, and the security patterns involved. No gaps are apparent.

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

Parameters2/5

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

The input schema has a single required 'path' parameter, but the description provides no explicit definition or example of what the path should represent. With 0% schema description coverage, the description must compensate, but it only implies the path via context. This is insufficient for unambiguous parameter understanding.

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 states the tool checks a repo's top-level directory for shadowed developer command names and the whole tree for external symlinks. This is specific, actionable, and distinguishes it from sibling tools which focus on IOCs and text manipulation.

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

Usage Guidelines4/5

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

The description explicitly advises running this tool 'before opening a freshly cloned or downloaded repository in an agentic coding tool,' and explains the security rationale. It does not provide explicit when-not-to-use guidance or alternatives, but the context is clear.

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/glatinone/secops-toolkit-mcp'

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