Back to skill

Security audit

speech-translation

Security checks for vulnerabilities and agentic risk

Overview

The skill is a coherent voice-translation pipeline, but its optional notifier hooks can execute arbitrary shell commands on the user’s machine.

Review before installing. Use the core pipeline only with trusted audio and trusted output paths. Do not enable transcript, translation, or audio command hooks unless you wrote and trust the exact command, because those hooks can run arbitrary shell commands and receive potentially sensitive spoken content. Prefer local LLM/Piper paths for private content, avoid unaudited HTTP translation services, and install dependencies in an isolated pinned environment.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • 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
Findings (2)

T09 · Insecure Skill Coding Practices

Error
Location
scripts/voice_translate_app/notifier.py:47
Finding

Shell Command Injection Through Notification Hooks

Content
View full analysis
None: if not command: return subprocess.run(command, input=text.encode("utf-8"), shell=True, check=True) def _run_audio_command(self, command: str | None, audio_file: Path) -> None: if not command: return if "{audio_file}" in command: resolved = command.format(audio_file=str(audio_file)) else: resolved = f'{command} "{audio_file}"' subprocess.run(resolved, shell=True, check=True) ``` Related standalone wrapper: ```python command = args.command_template.format(audio_file=shlex.quote(str(audio_path))) if args.dry_run: print(command) return subprocess.run(command, shell=True, check=True) ``` ### Technical Analysis Notification commands are accepted from command-line arguments or environment-backed command templates and passed to `subprocess.run` with `shell=True`. This causes the system shell to interpret command separators, substitutions, redirections, pipelines, and other metacharacters. The audio notifier introduces an additional injection boundary by interpolating `audio_file` directly into the shell command. In the placeholder branch, the path is inserted without any quoting. In the fallback branch, it is enclosed in double quotes but embedded quote characters are not escaped. Because the generated audio path includes the operator-provided output directory, an attacker who can influence that directory can potentially insert shell syntax into the resulting command. The standalone sender uses `shlex.quote` for the audio path, which protects that specif ...[truncated 1729 chars]
Remediation
View remediation

T08 · Insecure Dependencies

Warning
Location
references/runtime-notes.md:34
Finding

Unpinned Third-Party Runtime Dependencies

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
  • Behavioral ASTexec() Call, eval() Call, Dynamic Import
  • Taint TrackingDirect Taint Flow, Variable-Mediated Taint Flow, Credential Exfiltration Chain
Findings (40)

Tainted flow: 'message' from sys.stdin.read (line 43, user input) → subprocess.run (code execution)

Critical
Category
Data Flow
Confidence
90% confidence
Finding

External input (network, user) flows to a code execution sink. This enables remote code execution or command injection.

Content

Scanner excerpt · scripts/send_text.py (reported line 54)May include surrounding context.

python
"No command template provided. Use --command-template or set VOICE_TRANSLATE_TEXT_COMMAND_TEMPLATE."
        )

    subprocess.run(args.command_template, input=message.encode("utf-8"), shell=True, check=True)


if __name__ == "__main__":

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The documented workflow includes sending transcript text to an external translation service over HTTP and using manual fallback flows not reflected in the declared purpose. In a speech-translation context, transcripts commonly contain sensitive spoken content, so undocumented external transmission and mismatched behavior increase the risk of unintended data exposure and unsafe deployment assumptions.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The documented workflow includes sending transcript text to an external translation service over HTTP and using manual fallback flows not reflected in the declared purpose. In a speech-translation context, transcripts commonly contain sensitive spoken content, so undocumented external transmission and mismatched behavior increase the risk of unintended data exposure and unsafe deployment assumptions.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The documented workflow includes sending transcript text to an external translation service over HTTP and using manual fallback flows not reflected in the declared purpose. In a speech-translation context, transcripts commonly contain sensitive spoken content, so undocumented external transmission and mismatched behavior increase the risk of unintended data exposure and unsafe deployment assumptions.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The documented workflow includes sending transcript text to an external translation service over HTTP and using manual fallback flows not reflected in the declared purpose. In a speech-translation context, transcripts commonly contain sensitive spoken content, so undocumented external transmission and mismatched behavior increase the risk of unintended data exposure and unsafe deployment assumptions.

Content

No source excerpt is available for this finding.

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 134)May include surrounding context.

md
- Keep `SKILL.md` procedural and short.

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
97% confidence
Finding

This is a classic tool-parameter abuse issue: the executable behavior is delegated to a caller-controlled template and then run through the shell. In an agent skill context, this is more dangerous because automation, environment-variable configuration, or upstream user influence can turn a simple audio handoff into arbitrary local command execution, potentially exposing files, secrets, or enabling lateral actions.

Content

Scanner excerpt · scripts/send_audio.py (reported line 44)May include surrounding context.

python
print(command)
        return

    subprocess.run(command, shell=True, check=True)


if __name__ == "__main__":

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
99% confidence
Finding

This is a strong example of tool parameter abuse: a configurable command template directly controls a shell invocation and interpolates the audio_file parameter into it. In a skill that processes externally supplied audio and may operate automatically, this is especially dangerous because normal workflow inputs can become a trigger for arbitrary OS command execution without additional trust checks.

Content

Scanner excerpt · scripts/voice_translate_app/notifier.py (reported line 59)May include surrounding context.

python
resolved = command.format(audio_file=str(audio_file))
        else:
            resolved = f'{command} "{audio_file}"'
        subprocess.run(resolved, shell=True, check=True)

    def notify_transcript(self, text: str) -> None:
        self._run_text_command(self.transcript_command, text)

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
95% confidence
Finding

The skill advertises and instructs use of shell, file, environment, and network-capable operations but declares no explicit tool scope or permission boundaries. In an agent setting, this increases the chance that the skill can invoke high-risk capabilities without least-privilege constraints, enabling unintended command execution, filesystem modification, or outbound data transfer.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The skill documents sending transcript text to a translation service endpoint without any warning that spoken content may be transmitted off-host. Because transcripts may contain private conversations, credentials, business data, or regulated information, silent HTTP forwarding can cause confidentiality breaches and compliance issues, especially if users assume the workflow is local.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

This markdown file instructs the agent to transcribe inbound voice messages, translate them, and send translated audio, which are operations that affect user data and privacy. The description does not include any warning or disclosure that voice content will be processed, transformed, and returned through tools.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The transcript and translation templates hard-code Chinese headings ("转写结果" and "翻译结果") for user-visible output. This imposes a specific language on users without opt-in or justification, which is a natural-language locale policy concern.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The notes define an external HTTP translation service contract but do not clearly warn that transcript content—potentially sensitive spoken data—will be transmitted off-host to a network service. In a speech-translation skill, transcripts commonly contain private conversations or personal data, so omitting this disclosure increases the risk of unintentional data exfiltration and insecure deployment choices.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

This helper script is meant to send audio onward, but it does so by executing an arbitrary command template supplied via CLI or environment variable. That creates a generic command-execution surface not constrained to audio translation, so any process that can influence configuration can repurpose the skill to run unrelated system commands.

Content

No source excerpt is available for this finding.

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
96% confidence
Finding

The script builds a shell command from a user/environment-controlled template and executes it with shell=True. Even though the audio_file value is shell-quoted, the template itself is arbitrary and can include additional shell metacharacters or unrelated commands, enabling command injection or execution of attacker-chosen programs.

Content

Scanner excerpt · scripts/send_audio.py (reported line 44)May include surrounding context.

python
print(command)
        return

    subprocess.run(command, shell=True, check=True)


if __name__ == "__main__":

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

This code executes a shell command built from a user- or environment-supplied template via subprocess.run(..., shell=True). Although a dry-run mode exists, the normal execution path provides no confirmation prompt, no logging/print of the command being executed, and no inline warning comment or docstring disclosing that the script will invoke an external command to transmit the audio file.

Content

No source excerpt is available for this finding.

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
97% confidence
Finding

The script executes a caller-controlled command template with shell=True, allowing shell metacharacters, command chaining, and environment expansion to be interpreted by the shell. In this skill context, the command can be supplied from a CLI argument or environment variable, so a malicious or misconfigured workflow can trigger arbitrary command execution on the host running the agent.

Content

Scanner excerpt · scripts/send_text.py (reported line 54)May include surrounding context.

python
"No command template provided. Use --command-template or set VOICE_TRANSLATE_TEXT_COMMAND_TEMPLATE."
        )

    subprocess.run(args.command_template, input=message.encode("utf-8"), shell=True, check=True)


if __name__ == "__main__":

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The script forwards transcript/translation content to an external command without a clear runtime consent or warning boundary, which can leak sensitive spoken content to other processes or external services. In a speech-translation skill, inputs commonly contain private audio-derived text, making silent transmission more risky than in a generic utility.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The CLI exposes user-configurable command hooks for transcript, translation, and audio post-processing, which expands the tool from speech translation into arbitrary command execution. In an agent skill context, these options are especially dangerous because untrusted inputs or workflow configuration could cause execution of attacker-chosen local programs, leading to command injection or abuse of the host environment.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The notifier intentionally supports arbitrary external command execution that is broader than simple notification delivery. In the context of an audio translation skill, this materially expands the attack surface because routine workflow events can trigger execution of attacker-chosen host commands, turning a media-processing tool into a general code-execution primitive.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

This code executes external shell commands for transcript, translation, and audio notifications via subprocess.run(..., shell=True), but there is no confirmation prompt, visible logging, or user-facing warning in this file about that behavior. Because these commands can transmit text data or trigger arbitrary side effects, the lack of disclosure makes the operation insufficiently transparent to users.

Content

No source excerpt is available for this finding.

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
98% confidence
Finding

This executes a configured string via the system shell with shell=True, which enables arbitrary shell metacharacter parsing and command chaining. If the command value is influenced by a user, config file, environment, or untrusted workflow input, an attacker can achieve arbitrary command execution on the host; the translated/transcribed text sent to stdin does not remove that risk.

Content

Scanner excerpt · scripts/voice_translate_app/notifier.py (reported line 50)May include surrounding context.

python
def _run_text_command(self, command: str | None, text: str) -> None:
        if not command:
            return
        subprocess.run(command, input=text.encode("utf-8"), shell=True, check=True)

    def _run_audio_command(self, command: str | None, audio_file: Path) -> None:
        if not command:

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
100% confidence
Finding

This constructs a shell command from a configurable template and an audio file path, then executes it with shell=True. Because both shell expansion and Python format substitution are used, malicious command strings or crafted file paths can inject additional commands, leading to full arbitrary code execution and possible data exfiltration or system compromise.

Content

Scanner excerpt · scripts/voice_translate_app/notifier.py (reported line 59)May include surrounding context.

python
resolved = command.format(audio_file=str(audio_file))
        else:
            resolved = f'{command} "{audio_file}"'
        subprocess.run(resolved, shell=True, check=True)

    def notify_transcript(self, text: str) -> None:
        self._run_text_command(self.transcript_command, text)

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The embedded translation guide is entirely in Chinese, and the interactive prompt later also requires Chinese-language comprehension. This imposes a specific language on users without opt-in or explanation, which is a natural-language policy violation under the locale/language rule.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The prompt shown to users during interactive translation is only in Chinese, with no fallback or language selection. That creates a locale-specific experience not clearly justified in the file.

Content

No source excerpt is available for this finding.