Back to skill

Security audit

Houston Transtar Watch

Security checks for vulnerabilities and agentic risk

Overview

This skill is presented as a Houston traffic WhatsApp alert, but the registered runtime instead executes an external Python script outside the audited package.

Do not install this version without review or remediation. The traffic RSS parser itself is ordinary, but the skill entry point runs an external script that is not included in the reviewed package and the advertised WhatsApp delivery is not implemented in the inspected code.

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
main.py:19
Finding

Execution of an Unverified Python Script Outside the Audited Skill Package

Content
View full analysis

Vulnerability Details

File Location: main.py:19-25
Vulnerability Type: Execution of external, integrity-unverified local code
Risk Level: High

Vulnerable Code

python
async def perform(self, *args, **kwargs):
    # Use an absolute path to your scripts folder
    current_dir = os.path.dirname(os.path.abspath(__file__))
    # Adjust the number of ".." based on your folder depth
    script_path = os.path.join(current_dir, "..", "..", "scripts", "your_script.py")

    process = subprocess.run(["python", script_path], capture_output=True, text=True)
    return process.stdout

Technical Analysis

The registered skill's perform() method constructs a script path containing two parent-directory traversals and executes the resulting scripts/your_script.py file. The target lies outside the audited skill package and is not included in the reviewed project. The code performs no canonical-path boundary validation, ownership or permission check, integrity verification, or trusted-file verification before execution.

Although the subprocess call uses an argument list rather than a shell command and therefore does not directly introduce shell-command injection, it still establishes an unsafe code-execution boundary. Runtime behavior is determined by an external file that can differ from the code reviewed during installation or audit.

The target also does not match the bundled transtar.py implementations. Furthermore, SKILL.md:20-23 documents execution of transtar_diff.py, which is absent. This implementation-to-documentation mismatch makes the actual execution behavior less transparent and increases the likelihood that an unexpected external script will run.

Attack Path

  1. An attacker obtains write access to the external scripts directory resolved two levels above the skill package. This may occur through weak filesystem permissions, another compromised component, or an unsafe deployment process.
  2. The attacker creates or rep ...[truncated 1080 chars]
Remediation
View remediation

Remediation Suggestions

  1. Execute only the intended script shipped inside the audited skill package, such as scripts/transtar.py.
  2. Resolve the target to a canonical path and verify that it remains beneath the canonical skill directory before execution.
  3. Use sys.executable instead of the environment-dependent "python" executable.
  4. Reject symlinked or unexpectedly owned script files where the deployment model permits external modification.
  5. Apply restrictive filesystem permissions so untrusted users and unrelated components cannot modify executable skill files.
  6. Consider eliminating the subprocess boundary by importing and calling the bundled implementation directly.
  7. Add explicit failure handling by checking the subprocess return code, applying a timeout, and safely reporting standard error.
  8. Update SKILL.md so its runbook names the actual bundled entry point and remove references to the absent transtar_diff.py.

A hardened subprocess implementation could use the following pattern:

python
import os
import subprocess
import sys

async def perform(self, *args, **kwargs):
    skill_dir = os.path.realpath(os.path.dirname(__file__))
    script_path = os.path.realpath(
        os.path.join(skill_dir, "scripts", "transtar.py")
    )

    if os.path.commonpath([skill_dir, script_path]) != skill_dir:
        raise RuntimeError("Script path escapes the skill directory")

    process = subprocess.run(
        [sys.executable, script_path],
        capture_output=True,
        text=True,
        timeout=30,
        check=True,
    )
    return process.stdout
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Behavioral ASTexec() Call, eval() Call, Dynamic Import
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (13)

Tp4

High
Category
MCP Tool Poisoning
Confidence
96% confidence
Finding

The file presents a user-facing promise of periodic notifications but does not show the corresponding implementation, while implying filesystem-backed change tracking without declared permissions. Even if not malicious, this creates an integrity and transparency issue: users may authorize a seemingly simple alerting skill that actually depends on undeclared local state and opaque external logic.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The file presents a user-facing promise of periodic notifications but does not show the corresponding implementation, while implying filesystem-backed change tracking without declared permissions. Even if not malicious, this creates an integrity and transparency issue: users may authorize a seemingly simple alerting skill that actually depends on undeclared local state and opaque external logic.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The file presents a user-facing promise of periodic notifications but does not show the corresponding implementation, while implying filesystem-backed change tracking without declared permissions. Even if not malicious, this creates an integrity and transparency issue: users may authorize a seemingly simple alerting skill that actually depends on undeclared local state and opaque external logic.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The file presents a user-facing promise of periodic notifications but does not show the corresponding implementation, while implying filesystem-backed change tracking without declared permissions. Even if not malicious, this creates an integrity and transparency issue: users may authorize a seemingly simple alerting skill that actually depends on undeclared local state and opaque external logic.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
99% confidence
Finding

The implemented behavior does not match the manifest’s stated purpose of monitoring Houston TranStar RSS and sending WhatsApp alerts. Such capability mismatch is dangerous because it can conceal unrelated or unauthorized behavior, including arbitrary code execution, under the guise of a benign notification skill.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

A traffic-alert notification skill has no legitimate need to spawn a separate Python process to run another script. This unjustified execution primitive materially increases risk by enabling hidden functionality and expanding the attack surface beyond what users would reasonably expect from the skill.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
84% confidence
Finding

The skill declares an empty requires scope while its documented runbook indicates shell execution of a local Python script and behavior consistent with network access and stateful processing. Missing explicit tool/permission declarations weakens containment and review, because a reviewer or runtime may not understand that the skill can execute code and interact with external resources.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

A scheduled skill that automatically sends incident updates over WhatsApp can create privacy, consent, and nuisance risks if users are not clearly warned that outbound messages will be sent periodically. In this context the danger is lower than arbitrary code execution, but the absence of user warning reduces informed consent and may lead to unexpected data sharing or message volume.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
83% confidence
Finding

The comments and fallback import logic focus on bypassing loader/import problems rather than implementing the advertised RSS-monitoring behavior, which is a strong indicator of deceptive or at least poorly controlled development practices. This is dangerous in context because it helps mask the true runtime behavior and reduces trust in the skill’s declared purpose.

Content

No source excerpt is available for this finding.

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
95% confidence
Finding

The skill launches an external Python script via subprocess, which creates code-execution capability outside the declared skill logic. Even though the path is hardcoded, this is dangerous because the executed file can be changed independently of the skill and the behavior is hidden from users and reviewers.

Content

Scanner excerpt · main.py (reported line 25)May include surrounding context.

python
# Adjust the number of ".." based on your folder depth
        script_path = os.path.join(current_dir, "..", "..", "scripts", "your_script.py")
        
        process = subprocess.run(["python", script_path], capture_output=True, text=True)
        return process.stdout

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The skill executes an external process without any user-facing disclosure, consent, or warning, despite being presented as a simple traffic alert tool. Hidden execution is dangerous because users and operators cannot make informed trust decisions, and reviewers may overlook behavior that materially changes the skill’s risk profile.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

The manifest says the skill will 'WhatsApp me when there are changes,' which implies outbound messaging behavior. In code, the main flow fetches the RSS feed, computes diffs, saves local state, and prints a summary to stdout, but there is no WhatsApp API call, messaging integration, or any outbound notification implementation.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
87% confidence
Finding

The code writes a JSON snapshot to a state file under the user's home directory, which affects local user data persistently. While there is error logging, there is no prior comment, docstring, or user-facing message near the normal path that clearly tells the user that the script stores incident history on disk.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.