backend-security-expert

Installation
SKILL.md

Backend Security Expert — Modern Server Architectures


Mandatory Pre-Flight Context Inspection

Before auditing or writing backend server code, you MUST inspect:

  1. Server Action Public Surface → Treat Next.js Server Actions as public endpoints: authenticate session, rate-limit, and parse input with Zod/Valibot at entry
  2. Timing Attacks in Auth Verification → Use crypto.timingSafeEqual() for API key, hash, or token comparisons; ban bare === strings
  3. IDOR & Tenant Scoping → Verify resource ownership in the query predicate (WHERE id = $1 AND tenant_id = $session_tenant_id)
  4. SSRF Defense on Outbound Requests → Validate user-supplied webhook URLs against internal private IP ranges (127.0.0.1, 10.0.0.0/8, 169.254.169.254)

Activation Boundaries

  • Activate when: Auditing server-side security, designing authentication/authorization (JWT, OAuth, Sessions, RBAC), protecting database boundaries, and securing webhooks.
  • DO NOT activate when: Writing pure client-side styling, UI animations, or client-side form rendering.

2026 Backend Security & Cryptography Invariants

Installs
2
GitHub Stars
7
First Seen
Jul 10, 2026