Back to skill

Security audit

Claude Code within tmux

Security checks for vulnerabilities and agentic risk

Overview

The skill has a legitimate tmux-management purpose, but its command templates could run unintended local shell commands and can expose sensitive terminal history.

Review carefully before installing. Use it only for tmux sessions you control, verify the exact session and pane before sending anything, avoid passing untrusted prompt text through shell command templates, and treat captured scrollback as potentially sensitive.

Vulnerability Patterns
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (1)

T09 · Insecure Skill Coding Practices

Error
Location
SKILL.md:20
Finding

Shell Command Injection Through Untrusted tmux Workflow Placeholders

Content
View full analysis
" | grep -i claude ``` ```sh tmux send-keys -t -l -- "" sleep 0.1 tmux send-keys -t Enter ``` ### Technical Analysis The documented workflow places the user-controlled `` directly inside a double-quoted shell argument. Double quotes do not prevent shell command substitution through constructs such as `$(...)` or backticks. Consequently, a prompt containing shell substitution syntax may be executed by the local shell before `tmux` receives the prompt. The `tmux send-keys -l` option only tells tmux to treat the supplied keys literally. It does not protect the command from prior evaluation by the shell. The workflow also interpolates `` into a double-quoted `grep` expression and uses the derived `` as an unquoted shell argument. A crafted value containing quotes, command substitutions, shell separators, or option-like content could change the meaning of the generated command. Independently of command execution, treating the session name as a regular expression can cause incorrect pane selection. The vulnerability arises when an agent follows the skill by constructing and executing the displayed commands as shell text rather than passing values as opaque process arguments. ### Attack Path 1. An attacker asks the agent to send a prompt containing shell command-substitution syntax to a Claude tmux pane, or supplies a malicious session or target value. 2. The agent substitutes the attacker-controlled value into the command template from `SKILL.md`. 3. The resulting command is submitted to a shell. 4. The shell evaluates command substitutions or injected ...[truncated 1434 chars]
Remediation
View remediation
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
Findings (2)

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The skill directs the agent to inject arbitrary prompts into a live Claude session via tmux, which actively changes the state of that session and can trigger downstream actions in the attached project context. Without an explicit warning and confirmation step, a user may unknowingly cause side effects such as modifying files, changing conversation state, or sending commands to the wrong pane/session.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The raw buffer dump instruction captures and exposes a large portion of tmux scrollback, which may include sensitive prompts, secrets, internal reasoning, file contents, or unrelated conversation history from the pane. Because the skill presents this as a normal debug step without a disclosure warning or minimization guidance, it increases the risk of inadvertent data leakage.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.