Send a gdb command and return all output since the previous gdb_exec or gdb_interrupt call. Join multiple commands with \\n. Empty command only polls output. If session_id is empty or unknown, returns the current gdb session list instead of executing a command.
AI agents invoke gdb_exec to trigger actions in GDB Lite MCP. What it does depends on the arguments the agent supplies, and its effects often reach beyond the immediate call — builds kicked off, notifications sent, workflows started.
This tool executes arbitrary GDB commands in a debugging session. GDB allows running shell commands, modifying program memory, setting breakpoints, and controlling program execution. An AI agent could misuse this to run destructive or malicious operations via GDB's shell escape or memory manipulation capabilities. The blast radius is high because arbitrary GDB commands can affect the host system.
From the tool's definition Send a gdb command and return all output... Join multiple commands with \n
Attacks that exploit this kind of access
Send a gdb command and return all output since the previous gdb_exec or gdb_interrupt call. Join multiple commands with \\n. Empty command only polls output. If session_id is empty or unknown, returns the current gdb session list instead of executing a command. It is categorised as a Execute tool in the GDB Lite MCP MCP Server, which means it can trigger actions or run processes. Use rate limits and argument validation.
Register the GDB Lite MCP server in PolicyLayer and add a rule for gdb_exec: allow, deny, rate-limit, or require approval. Point your MCP client at the PolicyLayer proxy URL and the rule is enforced on every call, before it reaches GDB Lite MCP. Nothing to install.
gdb_exec is a Execute tool with high risk. Execute tools should be rate-limited and have argument validation enabled.
Yes. Add a rate_limit block to the gdb_exec rule in your PolicyLayer policy. For example, setting max: 10 and window: 60 limits the tool to 10 calls per minute. Rate limits are tracked per agent session and reset automatically.
Set action: deny in the PolicyLayer policy for gdb_exec. The AI agent will receive a policy violation error and cannot call the tool. You can also include a reason field to explain why the tool is blocked.
gdb_exec is provided by the GDB Lite MCP server (mort2000/gdb-lite-mcp). PolicyLayer sits as a proxy in front of this server to enforce policies before tool calls reach the server.
Every MCP server has a record like this.
Type a name, get the same breakdown: verified identity, auth posture, risk grade, capabilities, recommended policy.
Teams ship this data inside their own products. See what a licence covers →