# database-forensics

database-forensics is a Claude Code skill that inspects database files, transactional logs, and recovers deleted records. Runs during forensic investigations across server and embedded databases.

- skill · `type=skill` · Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf (Devin Desktop), Claude.ai · ★ 73 repo stars
- Author: W4L33Dx
- License: not stated · policy=link-only · description only; the file stays with the author
- Source: https://github.com/W4L33Dx/Cyber-Monster/tree/HEAD/blue-team/digital-forensics/database-forensics/SKILL.md
- Updated: 2026-11-15
- Security check: automated, 2026-11-17 (text) — no signs of malicious code found.
- HTML: https://affpapa.org/en/nevibecode/skills/database-forensics

## What it does

This skill guides the investigation of SQLite, PostgreSQL, MySQL, and Oracle storage artifacts. It enforces forensic preservation: taking SHA-256 hashes of all data files and log sidecars, working on filesystem snapshots, and forbidding live service restarts against original directories to prevent log replay from altering evidence.

For SQLite targets, it requires opening files with `immutable=1` alongside `-wal` or `-journal` sidecars, retrieving deleted rows from freelists via `.recover`. With PostgreSQL and MySQL, it examines write-ahead logs and binary logs for operation sequence. Whenever transactional telemetry is disabled or uncollected, the skill mandates reporting `INCONCLUSIVE (Telemetry Gap)` rather than a clean status.

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add W4L33Dx/Cyber-Monster --skill database-forensics -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/database-forensics/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/database-forensics/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add W4L33Dx/Cyber-Monster --skill database-forensics -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/database-forensics/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add W4L33Dx/Cyber-Monster --skill database-forensics -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/database-forensics/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install W4L33Dx/Cyber-Monster blue-team/digital-forensics/database-forensics
```

2. **Manually: put the files in place**
- File: `.github/skills/database-forensics/SKILL.md`

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add W4L33Dx/Cyber-Monster --skill database-forensics -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/W4L33Dx/Cyber-Monster --path blue-team/digital-forensics/database-forensics
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/database-forensics/SKILL.md` — The legacy .windsurf/skills/ path still works

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/W4L33Dx/Cyber-Monster/tree/HEAD/blue-team/digital-forensics/database-forensics/SKILL.md

## When to use it
- recover deleted SQLite rows from freelist pages
- trace transaction sequences across PostgreSQL WAL and MySQL binlogs
- verify database file integrity using SHA-256 hashes
- correlate application-level timestamps with database engine logs

## Example prompts
- Analyze this copied `app.db` with its `-wal` file to find deleted rows
- Inspect the PostgreSQL WAL stream to determine the sequence of updates on the accounts table
- Check the MySQL binlog for unauthorized table truncations

## Similar
- [sql-database-assistant](https://affpapa.org/en/nevibecode/skills/sql-database-assistant.md) — skill · 727 installs
- [database-documentation](https://affpapa.org/en/nevibecode/skills/database-documentation.md) — skill · 637 installs
- [database-schema-designer](https://affpapa.org/en/nevibecode/skills/borghei-database-schema-designer.md) — skill · 183 installs
- [memory-forensics-volatility](https://affpapa.org/en/nevibecode/skills/memory-forensics-volatility.md) — skill · 3900 installs
- [disk-forensics](https://affpapa.org/en/nevibecode/skills/disk-forensics.md) — skill · 456 installs
- [incident-response-forensics](https://affpapa.org/en/nevibecode/skills/incident-response-forensics.md) — skill · 254 installs

From the same set: [w4l33dx/cyber-monster](https://affpapa.org/en/nevibecode/by/w4l33dx/cyber-monster.md) — 61 cards

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
