T09 · Insecure Skill Coding Practices
- Location
SKILL.md:33- Finding
Unauthenticated Privileged Supabase Data Proxy with Caller-Controlled Query Selection
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
The skill is not deceptive or self-executing, but its dashboard template teaches an unsafe privileged Supabase proxy pattern that could expose sensitive admin data if copied into production.
Review this skill carefully before installing or using it to generate production code. If used, require authentication and authorization on every dashboard endpoint, avoid service-role keys for user-shaped reads where possible, hardcode safe table and column projections, bound pagination, encode upstream query parameters safely, and restrict CORS to explicit trusted origins.
SKILL.md:33Unauthenticated Privileged Supabase Data Proxy with Caller-Controlled Query Selection
SKILL.md:154Unrestricted Cross-Origin Resource Sharing Configuration
The example exposes a server endpoint that performs client-driven reads against Supabase using the service-role key, which bypasses row-level security and elevates every allowed read to highly privileged access. Even with a table allowlist, user-controlled table, select, limit, and offset parameters can enable broad extraction of sensitive administrative data from internal tables that were never meant to be readable by dashboard users.
The guidance recommends fully permissive CORS (allow_origins, allow_methods, and allow_headers all set to "*") for an admin dashboard backend without warning about the consequences. For a privileged dashboard API, this weakens origin-based isolation and makes it easier for arbitrary websites to issue cross-origin requests to the backend from a victim's browser, especially if authentication is later added via cookies or other ambient credentials.
Including wildcard CORS in instructional content for a Supabase-backed admin dashboard, without any security warning or scoping guidance, is unsafe because readers may copy it directly into production. In this context the backend fronts sensitive operational data, so normalizing permissive cross-origin access increases the chance of unintended data exposure or abuse once the API evolves beyond simple local development.