Logo vun Supabase Report

Supabase Report

Communautéit
yoanbernabeu
supabase-report

Generate a comprehensive Markdown security audit report with executive summary, findings, and remediation guidance.

Iwwersiicht

Editeuryoanbernabeu
Repositorysupabase-pentest-skills
Skill-Nummsupabase-report
Stären
75
Forks
5
Matgeliwwert Fichieren
Nëmmen Instruktiounen
Linken
  • Instruktiounen am Markdown-Format

    Eng SKILL.md-Datei, déi de Modell bei Bedarf luet, soudatt nëmmen Token ufalen, wann eng Ufro tatsächlech dozou passt.

  • Funktionéiert mat all LLM

    KI-Skills si reng Markdown, keen ubidderspezifesche Code. Dofir funktionéiert dëse Skill mat GPT, Claude, Gemini, Grok oder engem lokale Modell.

  • Alles an den Instruktiounen

    Alles, wat de Modell brauch, steet an den Instruktiounen — keng zousätzlech Dateien ze synchroniséieren.

  • Open Source

    Vum yoanbernabeu op GitHub verëffentlecht. Liest de Quelltext, ier Dir de Skill installéiert.

Installatioun

Installéiert de KI-Skill Supabase Report an TypingMind, fir e mat all LLM ze benotzen, oder füügt en an en anere KI-Agent an, deen SKILL.md liest.

1

An TypingMind installéieren

TypingMind installéiert e Skill direkt aus sengem GitHub-Dossier — dobäi gëtt SKILL.md gelies, d'Ressourcedateie gi gebëndelt an d'Resultat gëtt lokal gespäichert.

  1. Maacht d'App op a gitt op Plugins → Skills.
  2. Wielt „Vun GitHub installéieren“.
  3. Pecht d'URL vum Skill-Dossier hei drënner an a bestätegt.
    https://github.com/yoanbernabeu/supabase-pentest-skills/tree/main/skills/report/supabase-report
  4. Aktivéiert de Skill an all Chat, an deem Dir e benotze wëllt.
Plugins → Skills → Skill afügen → Vu GitHub-URL, pecht dann d'URL vum Dossier an a klickt op Weider.
2

An engem anere KI-Agent installéieren

All KI-Agent, deen d'Format Agent Skills liest, kann dëse Skill benotzen — kopéiert den Dossier an de Skill-Verzeechnes vun deem KI-Agent.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/yoanbernabeu/supabase-pentest-skills.git /tmp/supabase-pentest-skills
mkdir -p .claude/skills
cp -r /tmp/supabase-pentest-skills/skills/report/supabase-report .claude/skills/supabase-report
Start Claude Code nom Kopéieren nei, fir datt den neie Skill erkannt gëtt.

An TypingMind benotzen

Aktivéiert Supabase Report an engem Chat vun TypingMind, an de Modell iwwerhëlt de Rescht. Den Numm an d'Beschreiwung stinn am System-Prompt. Soubal eng Ufro dozou passt, luet de Modell déi komplett Instruktioune selwer — Dir musst de Skill ni manuell opruffen, an et fale keng Token un, bis en tatsächlech benotzt gëtt.

De Modell luet Supabase Report automatesch, soubal eng Ufro dozou passt.

Funktionéiert mat all KI-Modell

KI-Skills si reng Markdown-Instruktiounen amplaz vun ubidderspezifeschem Code. Dofir ass Supabase Report net un de Modell gebonnen, fir deen de Skill geschriwwe gouf. Installéiert en eemol an TypingMind a benotzt e mat GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama oder engem lokale Modell, deen Dir selwer bedreift — alles mat Ären eegenen API-Keys.

  • Gëtt nëmme gelueden, wann et néideg ass

    De System-Prompt enthält nëmmen den Numm an d'Beschreiwung. D'Instruktioune gi bei der éischter passender Ufro gelueden, soudatt en onbenotzte Skill näischt kascht.

  • De Modell am lafende Chat wiesselen

    Well de Skill aus Instruktiounen amplaz vu Code besteet, funktionéiert en och no engem Modellwiessel — den nächste Modell liest déi selwecht SKILL.md-Datei.

Skill-Instruktiounen

Dëst ass den Inhalt vu SKILL.md, deen de Modell luet. Liest e virun der Installatioun — e Skill besteet aus Instruktiounen, déi Äre Modell befollegt.

Security Report Generator

🔴 CRITICAL: PROGRESSIVE FILE UPDATES REQUIRED

You MUST write to context files AS YOU GO, not just at the end.

  • Write to .sb-pentest-audit.log IMMEDIATELY as you process each section
  • Update .sb-pentest-context.json with report metadata progressively
  • DO NOT wait until the entire report is generated to update files
  • If the skill crashes or is interrupted, the partial progress must already be saved

This is not optional. Failure to write progressively is a critical error.

This skill generates a comprehensive Markdown security audit report from all collected findings.

When to Use This Skill

  • After completing security audit phases
  • To document findings for stakeholders
  • To create actionable remediation plans
  • For compliance and audit trail purposes

Prerequisites

  • Audit phases completed (context file populated)
  • Findings collected in .sb-pentest-context.json

Report Structure

The generated report includes:

  1. Executive Summary — High-level overview for management
  2. Security Score — Quantified risk assessment
  3. Critical Findings (P0) — Immediate action required
  4. High Findings (P1) — Address soon
  5. Medium Findings (P2) — Plan to address
  6. Detailed Analysis — Per-component breakdown
  7. Remediation Plan — Prioritized action items
  8. Appendix — Technical details, methodology

Usage

Generate Report

Generate security report from audit findings

Custom Report Name

Generate report as security-audit-2025-01.md

Specific Sections

Generate executive summary only

Output Format

The skill generates supabase-audit-report.md:

markdown
# Supabase Security Audit Report

**Target:** https://myapp.example.com
**Project:** abc123def.supabase.co
**Date:** January 31, 2025
**Auditor:** Internal Security Team

---

## Executive Summary

### Overview

This security audit identified **12 vulnerabilities** across the Supabase implementation, including **3 critical (P0)** issues requiring immediate attention.

### Key Findings

| Severity | Count | Status |
|----------|-------|--------|
| 🔴 P0 (Critical) | 3 | Immediate action required |
| 🟠 P1 (High) | 4 | Address within 7 days |
| 🟡 P2 (Medium) | 5 | Address within 30 days |

### Security Score

**Score: 35/100 (Grade: D)**

The application has significant security gaps that expose user data and allow privilege escalation. Critical issues must be addressed before the application can be considered secure.

### Most Critical Issues

1. **Service Role Key Exposed** — Full database access possible
2. **Database Backups Public** — All data downloadable
3. **Admin Function No Auth** — Any user can access admin features

### Recommended Actions

1. ⚡ **Immediate (Today):**
   - Rotate service role key
   - Make backup bucket private
   - Add admin role verification

2. 🔜 **This Week:**
   - Enable RLS on all tables
   - Enable email confirmation
   - Fix IDOR in Edge Functions

3. 📅 **This Month:**
   - Strengthen password policy
   - Restrict CORS origins
   - Add rate limiting to functions

---

## Critical Findings (P0)

### P0-001: Service Role Key Exposed in Client Code

**Severity:** 🔴 Critical
**Component:** Key Management
**CVSS:** 9.8 (Critical)

#### Description

The Supabase service_role key was found in client-side JavaScript code. This key bypasses all Row Level Security policies and provides full database access.

#### Location

File: /static/js/admin.chunk.js Line: 89 Code: const SUPABASE_KEY = 'eyJhbGciOiJIUzI1NiI...'


#### Impact

- Full read/write access to all database tables
- Bypass of all RLS policies
- Access to auth.users table (all user data)
- Ability to delete or modify any data

#### Proof of Concept

```bash
curl 'https://abc123def.supabase.co/rest/v1/users' \
  -H 'apikey: [service_role_key]' \
  -H 'Authorization: Bearer [service_role_key]'

# Returns ALL users with full data
Remediation

Immediate:

  1. Rotate the service role key in Supabase Dashboard
    • Settings → API → Regenerate service_role key
  2. Remove the key from client code
  3. Redeploy the application

Long-term:

typescript
// Move privileged operations to Edge Functions
// supabase/functions/admin-action/index.ts

import { createClient } from '@supabase/supabase-js'

Deno.serve(async (req) => {
  // Service key only on server
  const supabase = createClient(
    Deno.env.get('SUPABASE_URL')!,
    Deno.env.get('SUPABASE_SERVICE_ROLE_KEY')!
  )

  // Verify caller is admin before proceeding
  // ...
})

Documentation:


P0-002: Database Backups Publicly Accessible

Severity: 🔴 Critical Component: Storage CVSS: 9.1 (Critical)

Description

The storage bucket named "backups" is configured as public, exposing database dumps, user exports, and environment secrets.

Exposed Files
FileSizeContent
db-backup-2025-01-30.sql125MBFull database dump
users-export.csv2.3MBAll user data with PII
secrets.env1KBAPI keys and passwords
Impact
  • Complete data breach (all database content)
  • Exposed credentials for third-party services
  • User PII exposed (emails, names, etc.)
Remediation

Immediate:

sql
-- Make bucket private
UPDATE storage.buckets
SET public = false
WHERE name = 'backups';

-- Delete or move files
-- Consider incident response procedures

Credential Rotation:

  • Stripe API keys
  • Database password
  • JWT secret
  • Any other keys in secrets.env

P0-003: Admin Edge Function Privilege Escalation

Severity: 🔴 Critical Component: Edge Functions CVSS: 8.8 (High)

Description

The /functions/v1/admin-panel Edge Function is accessible to any authenticated user without role verification.

[... additional P0 findings ...]


High Findings (P1)

P1-001: Email Confirmation Disabled

Severity: 🟠 High Component: Authentication

[... P1 findings ...]


Medium Findings (P2)

P2-001: Weak Password Policy

Severity: 🟡 Medium Component: Authentication

[... P2 findings ...]


Detailed Analysis by Component

API Security

TableRLSAccess LevelStatus
users❌Full read🔴 P0
orders✅None✅
posts✅Published only✅

Storage Security

BucketPublicSensitive FilesStatus
avatarsYesNo✅
backupsYesYes (45 files)🔴 P0

Authentication

SettingCurrentRecommendedStatus
Email confirmDisabledEnabled🟠 P1
Password min68+🟡 P2

Remediation Plan

Phase 1: Critical (Immediate)

IDActionOwnerDeadline
P0-001Rotate service keyDevOpsToday
P0-002Make backups privateDevOpsToday
P0-003Add admin role checkBackendToday

Phase 2: High Priority (This Week)

IDActionOwnerDeadline
P1-001Enable email confirmationBackend3 days
P1-002Fix IDOR in get-user-dataBackend3 days

Phase 3: Medium Priority (This Month)

IDActionOwnerDeadline
P2-001Strengthen password policyBackend14 days
P2-002Restrict CORS originsDevOps14 days

Appendix

A. Methodology

This audit was performed using the Supabase Pentest Skills toolkit, which includes:

  • Passive reconnaissance of client-side code
  • API endpoint testing with anon and service keys
  • Storage bucket enumeration and access testing
  • Authentication flow analysis
  • Real-time channel subscription testing

B. Tools Used

  • supabase-pentest-skills v1.0.0
  • curl for API testing
  • Browser DevTools for client code analysis

C. Audit Scope

  • Target URL: https://myapp.example.com
  • Supabase Project: abc123def
  • Components tested: API, Storage, Auth, Realtime, Edge Functions
  • Exclusions: None

D. Audit Log

Full audit log available in .sb-pentest-audit.log


Report generated by supabase-pentest-skills Audit completed: January 31, 2025 at 15:00 UTC


## Score Calculation

The security score is calculated based on:

| Factor | Weight | Calculation |
|--------|--------|-------------|
| P0 findings | -25 per issue | Critical vulnerabilities |
| P1 findings | -10 per issue | High severity issues |
| P2 findings | -5 per issue | Medium severity issues |
| RLS coverage | +10 if 100% | All tables have RLS |
| Auth hardening | +10 | Email confirm, strong passwords |
| Base score | 100 | Starting point |

### Grade Scale

| Score | Grade | Description |
|-------|-------|-------------|
| 90-100 | A | Excellent security posture |
| 80-89 | B | Good, minor improvements needed |
| 70-79 | C | Acceptable, address issues |
| 60-69 | D | Poor, significant issues |
| 0-59 | F | Critical, immediate action needed |

## Context Input

The report generator reads from `.sb-pentest-context.json`:

```json
{
  "target_url": "https://myapp.example.com",
  "supabase": {
    "project_url": "https://abc123def.supabase.co",
    "project_ref": "abc123def"
  },
  "findings": [
    {
      "id": "P0-001",
      "severity": "P0",
      "component": "keys",
      "title": "Service Role Key Exposed",
      "description": "...",
      "location": "...",
      "remediation": "..."
    }
  ],
  "audit_completed": "2025-01-31T15:00:00Z"
}

Report Customization

Include/Exclude Sections

Generate report without appendix
Generate report with executive summary only

Different Formats

Generate report in JSON format
Generate report summary as HTML

MANDATORY: Context File Dependency

⚠️ This skill REQUIRES properly populated tracking files.

Prerequisites

Before generating a report, ensure:

  1. .sb-pentest-context.json exists and contains findings from audit skills
  2. .sb-pentest-audit.log exists with timestamped actions
  3. All relevant audit skills have updated these files

If Context Files Are Missing

If context files are missing or empty:

  1. DO NOT generate an empty report
  2. Inform the user that audit skills must be run first
  3. Recommend running supabase-pentest for a complete audit

Report Generation Output

After generating the report, this skill MUST:

  1. Log to .sb-pentest-audit.log:

    [TIMESTAMP] [supabase-report] [START] Generating security report
    [TIMESTAMP] [supabase-report] [SUCCESS] Report generated: supabase-audit-report.md
    [TIMESTAMP] [supabase-report] [CONTEXT_UPDATED] Report generation logged
  2. Update .sb-pentest-context.json with report metadata:

    json
    {
      "report": {
        "generated_at": "...",
        "filename": "supabase-audit-report.md",
        "findings_count": { "p0": 3, "p1": 4, "p2": 5 }
      }
    }

FAILURE TO UPDATE CONTEXT FILES IS NOT ACCEPTABLE.

Related Skills

  • supabase-report-compare — Compare with previous reports
  • supabase-pentest — Run full audit first
  • supabase-help — List all available skills

Heefeg gestallte Froen

Wat mécht de KI-Skill Supabase Report?

Generate a comprehensive Markdown security audit report with executive summary, findings, and remediation guidance.

Firwat Supabase Report op TypingMind benotzen?

Well Dir en eemol installéiert a mat all Modell benotze kënnt. Supabase Report besteet aus einfachem Markdown amplaz vun ubidderspezifeschem Code. Dee selwechte Skill funktionéiert also mat GPT-5, Claude, Gemini, Grok oder engem lokale Modell – an Dir kënnt de Modell matzen am Chat wiesselen, ouni datt de Skill ophält ze funktionéieren. TypingMind benotzt Är eegen API-Schlësselen, sou datt Dir d'Ubidder direkt bezuelt amplaz vun engem Abonnement pro Benotzerplaz. Är Skills a Chats bleiwen an Ärem eegene Späicher.

Wéi installéieren ech Supabase Report an TypingMind?

Maacht an TypingMind Plugins → Skills → Vu GitHub installéieren op a setzt https://github.com/yoanbernabeu/supabase-pentest-skills/tree/main/skills/report/supabase-report an. TypingMind liest d'Datei SKILL.md an installéiert de Skill, deen Dir pro Chat aktivéiere kënnt.

Wéi eng KI-Modeller kënnen Supabase Report benotzen?

All Modell, deen Dir an TypingMind verbënnt. KI-Skills sinn einfach Markdown-Instruktiounen an net ubidderspezifesche Code. Dofir kënne GPT, Claude, Gemini, Grok a lokal Modeller dëse Skill lueden, wann eng Ufro dozou passt.

Wéi vill KI-Modeller kann ech mat Supabase Report benotzen?

Esou vill Dir wëllt. Soulaang e Modell Skills ënnerstëtzt, kënnt Dir Supabase Report domat benotzen – GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama a méi – alles op TypingMind mat Ären eegenen API-Schlësselen.

Ass de KI-Skill Supabase Report gratis?

De Skill gëtt vum yoanbernabeu op GitHub publizéiert. Kuckt am Repository no de Lizenzbedéngungen. Dir bezuelt nëmmen Ären eegene KI-Ubidder fir d'Token, déi Dir benotzt.

Wat si KI-Skills?

E KI-Skill ass e weiderverwendbaart Pak vun Instruktiounen, dat engem KI-Modell bäibréngt, wéi en eng bestëmmt Aufgab erfëllt. E follegt dem oppenen Agent Skills-Format: eng Datei SKILL.md mat engem Numm an enger Beschreiwung, plus all Scripten, Virlagen oder Referenzdateien, déi de Modell eventuell brauch. De Modell liest d'Instruktiounen eréischt, wann Är Ufro zum Skill passt. En installéierte Skill kascht also näischt, bis e benotzt gëtt.

Wéi ënnerscheede sech KI-Skills vu Plugins oder MCP-Serveren?

E Plugin oder MCP-Server gëtt engem Modell nei Tools, déi en opruffe kann – Code, deen iergendwou leeft an e Resultat zeréckgëtt. E KI-Skill gëtt dem Modell dogéint Wëssen an eng Virgoensweis: wéi en eng Aufgab ugeet, wéi eng Schrëtt en nokënnt a wéi eng gutt Ausgab ausgesäit. Skills bestinn aus einfachem Markdown, brauche kee Server, keen API-Schlëssel a keng Lafzäitëmfeld a funktionéiere mat all Modell.

All weisen

Elo Ären eegene KI-Workspace ariichten

Abonnéiert Iech op eisen Newsletter, fir iwwer nei Funktiounen an zukünfteg Gewënnspiller informéiert ze ginn 👇