Back to skill

Security audit

Deapi Audio

Security checks for vulnerabilities and agentic risk

Overview

The skill matches its audio purpose, but it needs Review because it can expose a stored API key and upload arbitrary local files or URL contents to deAPI without strong safeguards.

Install only if you are comfortable sending selected text, recordings, and voice samples to deAPI. Prefer setting `DEAPI_API_KEY` as an environment variable instead of saving it in `config.json`, avoid sharing logs or sessions that may contain the key, and only pass audio files or URLs you personally trust and have rights to use, especially for voice cloning.

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 (3)

T09 · Insecure Skill Coding Practices

Warning
Location
SKILL.md:32
Finding

Plaintext API Key Storage and Disclosure into Agent Context

Content
View full analysis
/dev/null || echo "NOT_CONFIGURED" If the config above is NOT_CONFIGURED, ask the user: - What is your deAPI API key? (get one at https://deapi.ai, free $5 credit) Then write the answer to ${CLAUDE_SKILL_DIR}/config.json as `{ "api_key": "their_key" }`. Alternatively, the user can set the `DEAPI_API_KEY` environment variable directly, which takes priority over config.json. ``` The corresponding credential-loading code is: ```bash deapi_check_auth() { if [[ -z "${DEAPI_API_KEY:-}" ]]; then # Try config.json fallback (written by skill setup flow) local config_file="${SCRIPT_DIR}/../config.json" if [[ -f "$config_file" ]]; then DEAPI_API_KEY=$(jq -r '.api_key // empty' "$config_file" 2>/dev/null) export DEAPI_API_KEY fi fi ``` ### Technical Analysis The setup procedure instructs the agent to save the deAPI bearer token directly in `config.json` as plaintext. It does not require restrictive file permissions, validate file ownership, or use an operating-system credential store. More critically, the dynamic instruction at `SKILL.md:33` reads the entire configuration file. Because the file contains the raw API key, loading or rendering this section can place the credential in agent context, execution traces, session transcripts, debugging output, or other records associated with the agent framework. The runtime fallback in `common.sh` also exports the recovered key into the process environment. This is needed for API authentication, but it increases exposure to child processes and should not be combined with unrestricted plaintext storage or context rendering. ### Attack Path 1. A user supplies a deAPI API key during ...[truncated 1151 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/common.sh:87
Finding

Unrestricted Local File Upload and Server-Side Request Forgery-Like URL Retrieval

Content
View full analysis
&2 rm -f "$tmp_file" return 1 fi echo "$tmp_file" else if [[ ! -f "$input" ]]; then echo "Error: File not found: $input" >&2 return 1 fi echo "$input" fi } ``` The speech-to-text caller uploads the resulting file without validating it: ```bash LOCAL_FILE=$(deapi_ensure_local_file "$AUDIO" "stt") || exit 1 CLEANUP_FILE="" [[ "$LOCAL_FILE" != "$AUDIO" ]] && CLEANUP_FILE="$LOCAL_FILE" # --- Build form data --- FORM_ARGS=() FORM_ARGS+=(-F "audio=@${LOCAL_FILE}") FORM_ARGS+=(-F "include_ts=${INCLUDE_TS}") FORM_ARGS+=(-F "model=WhisperLargeV3") # --- Submit job --- RESPONSE=$(deapi_submit_form "audiofile2txt" "${FORM_ARGS[@]}") ``` Voice cloning has the same data flow: ```bash LOCAL_FILE=$(deapi_ensure_local_file "$REF_AUDIO" "voiceclone") || exit 1 CLEANUP_FILE="" [[ "$LOCAL_FILE" != "$REF_AUDIO" ]] && CLEANUP_FILE="$LOCAL_FILE" # --- Build form data --- FORM_ARGS=() FORM_ARGS+=(-F "text=$(printf '%s' "$TEXT")") FORM_ARGS+=(-F "ref_audio=@${LOCAL_FILE}") FORM_ARGS+=(-F "model=Qwen3_TTS_12Hz_1_7B_Base") FORM_ARGS+=(-F "mode=voice_clone") FORM_ARGS+=(-F "voice=default") FORM_ARGS+=(-F "lang=${LANG}") FORM_ARGS+=(-F "speed=1") FORM_ARGS+=(-F "format=${FORMAT}") FORM_ARGS+=(-F "sample_rate=24000") ``` ### Technical Analysis The documentation claims that input is restricted to parti ...[truncated 2910 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Note
Location
scripts/text-to-speech.sh:88
Finding

JSON Request-Body Injection Through Unescaped Command-Line Parameters

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (19)

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The code’s primary behavior is narrowly limited to audio transcription (speech-to-text). It does match the declared transcription portion, including the note that video/YouTube transcription should use another skill. However, the declared description presents the skill as also providing text-to-speech, voice cloning, and voice design capabilities, none of which are present in the supplied code chunk. This is a material description-to-behavior mismatch because the declared purpose is substantially broader than what the code actually does.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The code chunk's primary behavior is straightforward text-to-speech generation through deAPI. It validates text input, applies model-specific defaults, submits a txt2audio request, and returns the generated audio metadata. There is no handling of audio file input, no speech-to-text/transcription flow, and no logic for cloning or designing voices beyond selecting a predefined/custom voice name parameter. Because the declared description presents broader capabilities than the supplied code actually provides, the description does not accurately represent this code chunk.

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 28)May include surrounding context.

md
| `scripts/voice-clone.sh` | User wants to clone/replicate a voice from a sample audio file |

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
| `scripts/voice-clone.sh` | User wants to clone/replicate a voice from a sample audio file |

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
| `scripts/voice-clone.sh` | User wants to clone/replicate a voice from a sample audio file |

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
| `scripts/voice-clone.sh` | User wants to clone/replicate a voice from a sample audio file |

Lp1

High
Category
MCP Least Privilege
Confidence
75% confidence
Finding

The skill uses 'shell' capability that is not listed in its permissions. This may indicate deceptive intent or missing permission declarations.

Content

No source excerpt is available for this finding.

Chaining Abuse

High
Category
Tool Misuse
Confidence
75% confidence
Finding

Tool calls are chained to bypass individual safety checks or escalate capabilities beyond what any single tool call would allow.

Content

Scanner excerpt · scripts/speech-to-text.sh (reported line 57)May include surrounding context.

sh
RESPONSE=$(deapi_submit_form "audiofile2txt" "${FORM_ARGS[@]}")

# Cleanup temp file
[[ -n "$CLEANUP_FILE" ]] && rm -f "$CLEANUP_FILE"

REQUEST_ID=$(deapi_extract_request_id "$RESPONSE") || exit 1
echo "Request ID: $REQUEST_ID" >&2

Chaining Abuse

High
Category
Tool Misuse
Confidence
75% confidence
Finding

Tool calls are chained to bypass individual safety checks or escalate capabilities beyond what any single tool call would allow.

Content

Scanner excerpt · scripts/voice-clone.sh (reported line 75)May include surrounding context.

sh
RESPONSE=$(deapi_submit_form "audiofile2txt" "${FORM_ARGS[@]}")

# Cleanup temp file
[[ -n "$CLEANUP_FILE" ]] && rm -f "$CLEANUP_FILE"

REQUEST_ID=$(deapi_extract_request_id "$RESPONSE") || exit 1
echo "Request ID: $REQUEST_ID" >&2

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The skill instructs the agent to request a deAPI API key and write it into a local config.json file, but it provides no warning about secret handling, file permissions, or avoiding accidental disclosure. In an agent environment, locally stored credentials may be exposed through later reads, logs, workspace sharing, backups, or other skills with file access.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
81% confidence
Finding

The skill is explicitly designed to send text and uploaded audio to an external service at api.deapi.ai, creating a real data-exfiltration boundary. In this context that behavior is expected, but it is still security-relevant because prompts, transcripts, and voice samples may contain sensitive, regulated, or biometric information and the reference does not surface consent, classification, or handling constraints.

Content

Scanner excerpt · references/api.md (reported line 3)May include surrounding context.

md
# Audio API Reference

Base URL: `https://api.deapi.ai/api/v1/client/`
Auth: `Authorization: Bearer $DEAPI_API_KEY`

## txt2audio

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

This markdown file documents voice_clone and transcription workflows that send user-provided audio files to a remote API, but it does not include any warning that the files leave the local system or may contain sensitive voice/recording data. For markdown files, SQP-2 applies when descriptions omit warnings about behaviors that could affect user data or privacy.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
60% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · scripts/common.sh (reported line 5)May include surrounding context.

sh
# deAPI shared utilities - sourced by skill scripts
# Usage: source "$(dirname "$0")/common.sh"

DEAPI_BASE_URL="https://api.deapi.ai/api/v1/client"
DEAPI_POLL_INTERVAL="${DEAPI_POLL_INTERVAL:-10}"
DEAPI_MAX_POLLS="${DEAPI_MAX_POLLS:-30}"

External Transmission

Medium
Category
Data Exfiltration
Confidence
70% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · scripts/common.sh (reported line 10)May include surrounding context.

sh
DEAPI_MAX_POLLS="${DEAPI_MAX_POLLS:-30}"

deapi_check_deps() {
  for cmd in curl jq; do
    if ! command -v "$cmd" &>/dev/null; then
      echo "Error: $cmd is required but not installed" >&2
      exit 1

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The script uploads user-supplied audio to a third-party remote API endpoint for transcription, but it does not provide an explicit runtime warning or confirmation that local files or referenced URLs will be transmitted off-host. In a voice/audio-processing skill, this matters because audio commonly contains sensitive personal, biometric, or confidential business data, so silent exfiltration to an external service creates a real privacy and compliance risk.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The script sends both arbitrary user text and a reference voice sample to a remote API for cloning, but it provides no explicit notice, consent check, or safety guard around ownership/authorization of the voice sample. In a voice-cloning context, that omission is materially risky because users may upload sensitive audio or clone someone else's voice without informed consent, creating privacy, impersonation, and compliance exposure.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
75% confidence
Finding

The reference instructs users to authenticate with Authorization: Bearer $DEAPI_API_KEY, which involves sensitive credentials, but the markdown does not warn users to protect the key or avoid exposing it in logs or shared scripts. Under SQP-2 for markdown, credential-handling behaviors that affect privacy or system integrity should be disclosed.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
83% confidence
Finding

The script sets LANG="English" by default, which imposes a specific language choice unless the user overrides it manually. This is a natural-language policy concern because the tool does not first ask for or otherwise obtain explicit user language preference.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
82% confidence
Finding

The script sets LANG="English" by default and presents usage examples that assume English unless the user overrides it. This imposes a language choice without explicit opt-in, which can conflict with language/locale policy guidance when no justification is provided.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.