Back to skill

Security audit

Supabase Ops

Security checks for vulnerabilities and agentic risk

Overview

The skill does what it claims, but it asks agents to run unpinned Supabase CLI commands for database and deployment operations that may use powerful credentials.

Review before installing. Use this only in projects where an agent is allowed to change Supabase schema and deploy edge functions. Prefer pinning the Supabase CLI in the project lockfile and replacing `npx supabase` with a verified local binary or `npx --no-install`. Keep service-role credentials server-side, limit production credentials, and require explicit approval before production database pushes or deployments.

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

T08 · Insecure Dependencies

Warning
Location
SKILL.md:49
Finding

Unpinned Supabase CLI Execution Through npx

Content
View full analysis
` for production. 5. Regenerate types: `npx supabase gen types typescript --local > src/lib/supabase/types.ts`. 6. Commit the migration and types: `git add supabase/ src/lib/supabase/types.ts && git commit -m "db: "`. ``` Additional affected commands from `SKILL.md:109`, `SKILL.md:112-113`, and `SKILL.md:139`: ```bash npx supabase functions new npx supabase functions serve npx supabase functions deploy npx supabase db reset ``` ### Technical Analysis An unqualified invocation such as `npx supabase` does not establish which exact package version must execute. If an appropriate local binary is unavailable, `npx` can retrieve a package from the configured npm registry. The effective executable can therefore change after the skill has been reviewed. The project contains no package manifest or lockfile pinning a specific Supabase CLI release. The documented commands also do not use `--no-install` or another mechanism that prevents on-demand package retrieval. Consequently, execution depends on mutable external package and registry state. This creates a supply-chain exposure because npm package installation and startup logic can execute with the privileges of the agent process. In this skill's intended environment, that process has filesystem and network permissions and may have Supabase credentials availabl ...[truncated 1912 chars]
Remediation
View remediation
``` 2. Commit the package manifest and lockfile, and require immutable installation in automation: ```bash npm ci ``` 3. Prevent `npx` from downloading a missing package at execution time: ```bash npx --no-install supabase db push npx --no-install supabase gen types typescript --local npx --no-install supabase functions deploy ``` Invoking the verified local binary directly is another acceptable option: ```bash ./node_modules/.bin/supabase db push ``` 4. Verify lockfile integrity and dependency provenance in trusted CI. Use registry allowlisting, dependency review, and package-signature or provenance checks where supported. 5. Run dependency installation separately from credential-bearing database operations. Do not expose `SUPABASE_SERVICE_ROLE_KEY` during package installation. 6. Provide the service-role credential only to operations that strictly require it, use a dedicated least-privilege environment, and avoid inheriting unrelated secrets into CLI subprocesses. 7. Pin remote dependencies used by generated Edge Functions to reviewed immutable versions where practical, and periodically review pinned updates before adoption. ]]>
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (9)

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

The skill repeatedly instructs use of npx supabase without pinning an exact package version. Because npx may fetch the latest CLI from the registry at execution time, behavior can change unexpectedly or a compromised upstream package version could execute arbitrary code in an environment that has access to Supabase credentials and can perform schema changes or deploy edge functions.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The skill claims credentials are accessed exclusively through the Supabase CLI and never read directly from env files, but the embedded edge function template explicitly reads SUPABASE_URL and SUPABASE_SERVICE_ROLE_KEY via Deno.env.get(...). This inconsistency can mislead operators about secret handling boundaries and normalize direct use of a highly privileged service role key inside function code, increasing the chance of improper secret exposure or unsafe deployment assumptions.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

The production variant on this line also relies on unpinned npx supabase, which is especially risky because it targets production databases. A compromised or incompatible CLI version could alter production schema or data while running with privileged access.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
94% confidence
Finding

Type generation via unpinned npx supabase still executes code fetched at runtime. While the direct impact is lower than schema mutation, the command runs in a credentialed development environment and could still execute malicious code or generate incorrect types that mask later security issues.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

Creating edge functions with an unpinned CLI introduces supply-chain risk and non-reproducible behavior. Since this skill manages deployment-capable operations, a malicious or changed CLI could scaffold insecure code or perform unexpected actions in the repository.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

Serving functions locally with an unpinned CLI still executes untrusted, registry-fetched code in a development environment that may hold project secrets. This creates avoidable supply-chain exposure and inconsistent behavior across runs.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
96% confidence
Finding

Deploying edge functions with unpinned npx supabase is high risk because it combines runtime package fetching with a deployment action. A malicious or altered CLI could deploy unintended code, exfiltrate secrets, or modify remote project configuration.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
94% confidence
Finding

Unpinned type generation remains a genuine supply-chain and reproducibility issue. Although this command is not directly destructive, it still runs external code and can silently alter generated types in ways that mislead developers and downstream security checks.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

The seed/reset workflow uses unpinned npx supabase for a destructive operation that drops and recreates the database in development. If a malicious or incompatible CLI is fetched, it could execute arbitrary code locally or perform broader destructive actions than intended.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.