一键导入
supabase-extract-url
Extract the Supabase project URL from client-side JavaScript code, environment variables, and configuration files.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Extract the Supabase project URL from client-side JavaScript code, environment variables, and configuration files.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Orchestrate a complete Supabase security audit with guided step-by-step execution and ownership confirmation.
Test Row Level Security (RLS) policies for common bypass vulnerabilities and misconfigurations.
List and test exposed PostgreSQL RPC functions for security issues and potential RLS bypass.
List all tables exposed via the Supabase PostgREST API to identify the attack surface.
Attempt to read data from exposed tables to verify actual data exposure and RLS effectiveness.
Analyze Supabase authentication configuration for security weaknesses and misconfigurations.
| name | supabase-extract-url |
| description | Extract the Supabase project URL from client-side JavaScript code, environment variables, and configuration files. |
🔴 CRITICAL: PROGRESSIVE FILE UPDATES REQUIRED
You MUST write to context files AS YOU GO, not just at the end.
- Write to
.sb-pentest-context.jsonIMMEDIATELY after each discovery- Log to
.sb-pentest-audit.logBEFORE and AFTER each action- DO NOT wait until the skill completes to update files
- If the skill crashes or is interrupted, all prior findings must already be saved
This is not optional. Failure to write progressively is a critical error.
This skill extracts the Supabase project URL from a web application's client-side code.
The skill scans for URL patterns in:
// Direct URL references
const SUPABASE_URL = 'https://abc123.supabase.co'
createClient('https://abc123.supabase.co', key)
// Environment variable patterns
process.env.SUPABASE_URL
process.env.NEXT_PUBLIC_SUPABASE_URL
import.meta.env.VITE_SUPABASE_URL
<meta name="supabase-url" content="https://abc123.supabase.co">
<script>
window.SUPABASE_URL = 'https://abc123.supabase.co'
</script>
const config = {
supabase: {
url: 'https://abc123.supabase.co'
}
}
Recognized patterns:
| Pattern | Example |
|---|---|
| Standard | https://abc123.supabase.co |
| With region | https://abc123.eu-central-1.supabase.co |
| Custom domain | Detected via API endpoint patterns |
Extract Supabase URL from https://myapp.example.com
If you have downloaded the source:
Extract Supabase URL from ./dist/assets/
═══════════════════════════════════════════════════════════
SUPABASE URL EXTRACTED
═══════════════════════════════════════════════════════════
Project URL: https://abc123def.supabase.co
Project Ref: abc123def
Region: us-east-1 (inferred)
Found in:
├── /static/js/main.abc123.js (line 1247)
│ └── const SUPABASE_URL = 'https://abc123def.supabase.co'
│
└── /static/js/chunk.def456.js (line 89)
└── createClient('https://abc123def.supabase.co', ...)
API Endpoints:
├── REST API: https://abc123def.supabase.co/rest/v1/
├── Auth API: https://abc123def.supabase.co/auth/v1/
├── Storage: https://abc123def.supabase.co/storage/v1/
└── Realtime: wss://abc123def.supabase.co/realtime/v1/
Context updated: .sb-pentest-context.json
═══════════════════════════════════════════════════════════
Saved to .sb-pentest-context.json:
{
"supabase": {
"project_url": "https://abc123def.supabase.co",
"project_ref": "abc123def",
"region": "us-east-1",
"endpoints": {
"rest": "https://abc123def.supabase.co/rest/v1/",
"auth": "https://abc123def.supabase.co/auth/v1/",
"storage": "https://abc123def.supabase.co/storage/v1/",
"realtime": "wss://abc123def.supabase.co/realtime/v1/",
"functions": "https://abc123def.supabase.co/functions/v1/"
},
"sources": [
{
"file": "/static/js/main.abc123.js",
"line": 1247,
"context": "const SUPABASE_URL = 'https://abc123def.supabase.co'"
}
]
}
}
If multiple Supabase URLs are found:
═══════════════════════════════════════════════════════════
MULTIPLE SUPABASE URLS FOUND
═══════════════════════════════════════════════════════════
⚠️ Multiple Supabase projects detected
1. https://abc123.supabase.co (primary - most references)
└── Found in: main.js, config.js
2. https://xyz789.supabase.co (secondary)
└── Found in: analytics.js
Using primary URL for further analysis.
To use a different URL, specify it manually.
═══════════════════════════════════════════════════════════
The skill validates extracted URLs by:
Validation:
├── Format: ✅ Valid Supabase URL format
├── Reachable: ✅ REST API responds (200 OK)
└── Confirmed: ✅ Response matches Supabase pattern
❌ Problem: URL not found despite Supabase detection ✅ Solution: The URL may be in a dynamically loaded chunk. Try:
Extract URL with deep scan from https://myapp.example.com
❌ Problem: URL found but validation fails ✅ Solution: The project may be paused or the region may have connectivity issues. The URL is still recorded.
❌ Problem: Only custom domain found ✅ Solution: Custom domains are valid. The skill will note it as a custom domain and attempt to identify the underlying project.
After extracting the URL:
supabase-extract-anon-key to find the API keysupabase-extract-service-key to check for leaked service keys⚠️ This skill MUST update tracking files PROGRESSIVELY during execution, NOT just at the end.
DO NOT batch all writes at the end. Instead:
.sb-pentest-audit.log.sb-pentest-context.json.sb-pentest-audit.logThis ensures that if the skill is interrupted, crashes, or times out, all findings up to that point are preserved.
Update .sb-pentest-context.json with extracted data:
{
"supabase": {
"project_url": "https://[ref].supabase.co",
"project_ref": "[ref]",
"endpoints": { ... }
}
}
Log to .sb-pentest-audit.log:
[TIMESTAMP] [supabase-extract-url] [START] Beginning URL extraction
[TIMESTAMP] [supabase-extract-url] [SUCCESS] URL extracted: https://[ref].supabase.co
[TIMESTAMP] [supabase-extract-url] [CONTEXT_UPDATED] .sb-pentest-context.json updated
If files don't exist, create them before writing.
FAILURE TO UPDATE CONTEXT FILES IS NOT ACCEPTABLE.
📁 Evidence Directory: .sb-pentest-evidence/02-extraction/
| File | Content |
|---|---|
extracted-url.json | URL extraction details with source locations |
{
"evidence_id": "EXT-URL-001",
"timestamp": "2025-01-31T10:05:00Z",
"category": "extraction",
"type": "url_extraction",
"extracted_data": {
"project_url": "https://abc123def.supabase.co",
"project_ref": "abc123def",
"region": "us-east-1"
},
"sources": [
{
"file": "/static/js/main.js",
"line": 1247,
"context": "const SUPABASE_URL = 'https://abc123def.supabase.co'"
}
],
"endpoints_discovered": {
"rest": "https://abc123def.supabase.co/rest/v1/",
"auth": "https://abc123def.supabase.co/auth/v1/",
"storage": "https://abc123def.supabase.co/storage/v1/",
"realtime": "wss://abc123def.supabase.co/realtime/v1/"
}
}
supabase-detect — Detect Supabase usage firstsupabase-extract-anon-key — Extract the anon keysupabase-extract-service-key — Check for service key leaks