Back to skill

Security audit

Tinyfish Browser

Security checks for vulnerabilities and agentic risk

Overview

This skill does what it says: it creates TinyFish remote browser sessions, though users should understand it sends URLs and an API key to TinyFish.

Install only if you intend to use TinyFish as a third-party hosted browser provider. Treat target URLs and browser activity as data sent to TinyFish, keep TINYFISH_API_KEY scoped and rotated as needed, and consider hardening the helper so the API key is not visible in process arguments.

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

Warning
Location
scripts/browser.sh:25
Finding

TinyFish API Key Exposed Through Process Command-Line Arguments

Content
View full analysis

Vulnerability Details

File Location: scripts/browser.sh, lines 25-29
Vulnerability Type: Sensitive credential exposure through process arguments
Risk Level: Medium

bash
exec curl -s -X POST "https://api.browser.tinyfish.ai" \
  -H "X-API-Key: ${TINYFISH_API_KEY}" \
  -H "Content-Type: application/json" \
  -d "$BODY"

Technical Analysis

The script expands TINYFISH_API_KEY directly into a command-line argument passed to curl. While the key is transmitted to the intended service over HTTPS, its presence in the local process argument list can expose it through process-inspection interfaces and monitoring tools.

Depending on the operating system and process-isolation configuration, another local user or process may be able to retrieve the header from utilities such as ps or from process metadata such as /proc/<pid>/cmdline. Process auditing and telemetry systems may also record the complete command line, causing the credential to persist in logs after the request finishes.

Attack Path

  1. A victim invokes scripts/browser.sh while TINYFISH_API_KEY contains a valid credential.
  2. The script starts curl with the complete X-API-Key header in its process arguments.
  3. During the request, an attacker with sufficient local process-inspection access observes the curl command line.
  4. The attacker extracts the TinyFish API key from the header argument.
  5. The attacker submits requests directly to the TinyFish Browser API using the stolen credential.
  6. The attacker can create unauthorized remote browser sessions within the permissions and usage limits assigned to that API key.

Exploitation requires local process-observation capability or access to command-line telemetry collected by the host. The vulnerability does not independently provide remote code execution or elevated operating-system privileges.

Impact Assessment

Successful exploitation compromises the confid ...[truncated 521 chars]

Remediation
View remediation

Remediation Suggestions

Avoid placing the API key directly in curl command-line arguments.

  • Pass the sensitive header through a protected configuration file or file descriptor rather than through -H on the command line.
  • If a temporary configuration file is necessary, create it with restrictive permissions such as mode 0600, store it in a trusted directory, and remove it reliably with a shell trap.
  • Prefer an anonymous pipe or another mechanism that does not persist the secret on disk.
  • Ensure process-monitoring and audit systems redact authorization headers and API keys.
  • Rotate the existing TinyFish API key if it may have been exposed through process inspection or logging.
  • Add curl --fail-with-body or equivalent status handling so HTTP failures are reported reliably.

One possible hardening pattern is to provide a protected curl configuration over standard input:

bash
printf 'header = "X-API-Key: %s"\n' "$TINYFISH_API_KEY" |
  curl --fail-with-body --silent --show-error \
    --config - \
    -X POST "https://api.browser.tinyfish.ai" \
    -H "Content-Type: application/json" \
    -d "$BODY"

Before adopting this pattern, verify that the target platform does not expose pipe contents through its diagnostics or telemetry and that failures cannot echo the configuration containing the secret.

Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (5)

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
94% confidence
Finding

The skill invokes shell commands (curl, shell preflight check, helper script) but does not declare any tool scope such as permissions or allowed-tools. This weakens least-privilege controls and makes it easier for an agent runtime to execute shell-capable behavior without explicit user or platform visibility into that requirement.

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 · SKILL.md (reported line 29)May include surrounding context.

Create a Session

bash
curl -X POST "https://api.browser.tinyfish.ai" \
  -H "X-API-Key: $TINYFISH_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "url": "https://example.com" }'

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% 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 · SKILL.md (reported line 49)May include surrounding context.

{ "session_id": "sess_abc123", "cdp_url": "wss://browser.tinyfish.ai/devtools/browser/…", "base_url": "https://api.browser.tinyfish.ai/sessions/sess_abc123" }

text

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/browser.sh (reported line 27)May include surrounding context.

sh
BODY=$(python3 -c "import json,sys; print(json.dumps({'url': sys.argv[1]}))" "$URL")

exec curl -s -X POST "https://api.browser.tinyfish.ai" \
  -H "X-API-Key: ${TINYFISH_API_KEY}" \
  -H "Content-Type: application/json" \
  -d "$BODY"

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

This code file performs a network POST to an external API and includes both the user-provided URL in the request body and the API key in a header. While the file has a brief header comment, it does not warn the user that input will be transmitted to a third-party service, which is a safety-relevant disclosure for code files.

Content

No source excerpt is available for this finding.