Back to skill

Security audit

scheduler for discord

Security checks for vulnerabilities and agentic risk

Overview

The skill is a scheduler, but its examples put user-written reminder text into shell commands in a way that could run unintended commands.

Review before installing. This skill should be changed to pass cron arguments through a structured API or safely escaped argument array, validate channel IDs and job names, and make recurring jobs easy to list and delete. Use it only with trusted inputs until that is fixed.

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
skills.md:35
Finding

Shell Command Injection Through Unsafely Interpolated Reminder Content

Content
View full analysis
" \ --session isolated \ --at 2m \ --agent main \ --message "" \ --deliver \ --channel discord \ --to channel: \ --delete-after-run ``` ### Technical Analysis The skill directs the agent to invoke `moltbot cron` through the shell-backed `exec` tool and interpolate reminder content into the `--message` argument. The reminder text originates from the user and is therefore untrusted. Wrapping the value in double quotes does not prevent shell evaluation. Command substitutions using `$(...)` or backticks are evaluated inside double-quoted strings. Embedded quotation marks may also terminate the intended argument and permit the addition of shell operators or commands. The instructions do not require shell-safe escaping, structured argument passing, input validation, or any other mechanism that ensures the message is treated exclusively as literal data. Other dynamic values in the command, including the job name and channel identifier, should also be considered untrusted unless obtained from a trusted context and strictly validated. ### Attack Path 1. An attacker submits a scheduling request containing shell syntax in the reminder text, such as `$(malicious-command)`. 2. The agent places that text into the documented `--message ""` command template. 3. The agent sends the resulting command to the shell-backed `exec` tool. 4. The shell evaluates the command substitution before starting `moltbot`. 5. The injected command executes with the operating-system privileges and environment available to the agent process. 6. After executing the injected command, the shell may still invoke `moltbot`, potentially concealing the compromise behi ...[truncated 1009 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 (1)

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
84% confidence
Finding

The recurring-job example sets --tz "Asia/Shanghai" directly, which can steer agents toward a specific locale without confirming the user's preferred timezone. Because the policy scope includes language/locale constraints in natural-language or config-like content, this is a mild locale-policy concern unless the skill clearly frames it as only an example to be replaced.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.