December 2026 Series • 1/24 Published

2026 DevSec Advent Calendar

Twenty-four focused security briefs for frontend, Node.js, and DevOps engineers. Each door explores a concrete attack vector backed by real-world incidents & advisories, why default configurations fail, and a production-ready fix you can verify and ship in minutes.

Series Progress 1 of 24 Days (4%)
Day 00 • Zero-Day Intro 7 min read

Day 00 (Zero-Day): Why I Built a 24-Day DevSec Advent Calendar

Launching December 1: an AI-assisted deep dive into my own security knowledge gaps as CVEs skyrocket across the web stack, sharing 24 practical daily briefs with anyone on the same journey.

Start Here

Week 1: Frontend & Browser Traps

Content Security Policy exfiltration guards, route isolation, dev server bindings, HttpOnly cookies, postMessage validation, and Subresource Integrity.

Day 01 5 min read

CSP connect-src Isn't Optional: Stopping Compromised Third-Party Scripts

Allowlisting a vendor <script> in script-src isn't enough. Locking down connect-src prevents a compromised third-party script from exfiltrating scraped data to attacker-controlled domains.

Read Day 01 →
Day 02 Locked

Keep Third-Party Tags Off Sensitive Routes

Analytics, chat widgets, and A/B testing scripts have zero business executing on /login, /checkout, /billing, or /settings. Isolate sensitive routes from tag managers and use hosted payment iframes.

2026-12-02 Unlocks Dec 02
Day 03 Locked

Dev Servers Belong on localhost: Why 0.0.0.0 Turns Into RCE

Hardcoding vite --host or server.host: true (0.0.0.0) in package.json or mapping -p 5173:5173 in Docker exposes your dev server to local networks and browser pivot attacks.

2026-12-03 Unlocks Dec 03
Day 04 Locked

Stop Storing Auth Tokens in localStorage

Any XSS bug or poisoned npm dependency can read localStorage and sessionStorage in a single line of JS. Store session tokens in HttpOnly, Secure, SameSite cookies instead.

2026-12-04 Unlocks Dec 04
Day 05 Locked

window.postMessage Without event.origin Checks Is DOM XSS Waiting to Happen

Listening to window.addEventListener('message', ...) without strictly validating event.origin against an exact allowlist lets any malicious popup or iframe inject untrusted payloads into your app.

2026-12-05 Unlocks Dec 05
Day 06 Locked

Subresource Integrity (SRI) for Static CDNs

If you load a versioned script or stylesheet from a public CDN without an integrity="sha384-..." hash and crossorigin="anonymous", a CDN compromise turns into arbitrary code execution.

2026-12-06 Unlocks Dec 06

Week 2: Secrets, Tokens & AI Tooling

Auditing forgotten PATs, sandboxing untrusted repos, hardening IDE extensions & MCP servers, keeping secrets out of docs/prompts, CI OIDC federation, and Git history scanning.

Day 07 Locked

Audit Your Forgotten GitHub & GitLab PATs

Revoke personal access tokens created 'temporarily' two years ago. Replace classic broad-scope PATs with fine-grained, repository-scoped tokens with mandatory expiration dates.

2026-12-07 Unlocks Dec 07
Day 08 Locked

Never Run Untrusted Repos on Your Host Machine

Coding interview take-home assignments, random GitHub PoCs, and 'troubleshooting scripts' belong inside a disposable VM or isolated container, never on your primary laptop next to ~/.ssh and ~/.aws.

2026-12-08 Unlocks Dec 08
Day 09 Locked

Treat IDE Extensions & MCP Servers Like Prod Dependencies

AI coding agents, MCP servers, and IDE extensions execute with your full local OS user permissions. Verify publisher identities, pin versions, and audit tool permissions.

2026-12-09 Unlocks Dec 09
Day 10 Locked

Stop Pasting Raw Secrets Into Docs, Tickets, and AI Prompts

Pasting .env files, database URIs, or API tokens into Slack threads, Google Docs, Jira tickets, or non-private AI sessions creates a searchable treasure map when a single SaaS account is compromised.

2026-12-10 Unlocks Dec 10
Day 11 Locked

Replace Static CI Secrets With OIDC Federation

Stop storing long-lived AWS/GCP/Azure JSON keys in GitLab CI or GitHub Actions variables. Use OpenID Connect (OIDC) federation so pipelines mint short-lived, job-scoped credentials that expire automatically.

2026-12-11 Unlocks Dec 11
Day 12 Locked

.env in .gitignore Isn't Enough: Scanning Git History for Secrets

Adding .env to .gitignore does nothing if the file was already tracked, and deleting a secret in a follow-up commit leaves it intact in git history. Enforce pre-commit hooks and CI secret scanning.

2026-12-12 Unlocks Dec 12

Week 3: Dependencies & Supply Chain

Deterministic frozen lockfiles, disabling postinstall lifecycle scripts, patching transitive trees, pinning Docker digests, non-root containers, and stack-aware CVE triage.

Day 13 Locked

Commit Lockfiles & Enforce --frozen-lockfile (npm ci)

Running npm install or pnpm install without --frozen-lockfile in CI can silently pull unreviewed minor/patch versions into production builds. Always use npm ci or pnpm install --frozen-lockfile.

2026-12-13 Unlocks Dec 13
Day 14 Locked

Lifecycle Scripts (postinstall) Are Silent RCE

Any package in your dependency tree can execute arbitrary shell commands during npm install via preinstall/postinstall hooks. Audit packages with lifecycle scripts and use --ignore-scripts or allowlists.

2026-12-14 Unlocks Dec 14
Day 15 Locked

Audit Transitive Dependencies, Not Just package.json

Your top-level package.json can look spotless while a nested dependency three levels deep carries a CVSS 9.1 flaw. Use npm ls and version-scoped lockfile overrides to patch deep dependency trees.

2026-12-15 Unlocks Dec 15
Day 16 Locked

Pin Docker Base Images by SHA256 Digest

Mutable tags like node:22-alpine or nginx:alpine can change silently between builds. Pin base images by immutable @sha256:... digest and automate updates with Renovate or Dependabot.

2026-12-16 Unlocks Dec 16
Day 17 Locked

Don't Run Node & Web Containers as root

Docker containers run as UID 0 (root) by default. Adding USER node or running unprivileged nginx restricts filesystem writes and drastically reduces blast radius if an attacker achieves RCE.

2026-12-17 Unlocks Dec 17
Day 18 Locked

Automate CVE Triage Against Your Actual Stack

Reading every security newsletter manually leads to patch fatigue. Pipe official vendor advisories against your actual repo SBOMs/manifests so you only alert on CVEs that match your deployed versions.

2026-12-18 Unlocks Dec 18

Week 4: Backend, Databases & Ops

Least-privilege database runtime roles, firewalling database wire ports, SSRF outbound validation, headless Chromium container rebuilds, tenant-scoped RBAC/IDOR guards, and the holiday freeze checklist.

Day 19 Locked

Split Your DB Migration User From Your Runtime App User

Your runtime application role only needs SELECT, INSERT, UPDATE, DELETE, never CREATE or ALTER TABLE rights. Separating DDL migration users from runtime users blocks privilege escalation and host RCE chains.

2026-12-19 Unlocks Dec 19
Day 20 Locked

Firewall Internal Database Ports (5432, 1521, 6379)

Database wire protocols aren't designed to face untrusted networks. Pre-authentication bugs can crash or compromise database servers before a login handshake even finishes. Keep DB ports strictly inside private subnets.

2026-12-20 Unlocks Dec 20
Day 21 Locked

Validate Outbound URLs to Kill SSRF

Any backend endpoint that fetches a user-supplied URL (webhooks, avatar importers, link previews, PDF generators) can be abused to query internal services or cloud metadata (169.254.169.254). Pin resolved IPs at connect time to stop SSRF and DNS rebinding.

2026-12-21 Unlocks Dec 21
Day 22 Locked

Rebuild Headless Chromium Containers on Every Browser CVE

Patching Chrome on your laptop doesn't protect your Node/Puppeteer/Playwright microservice rendering PDFs or screenshots in Docker. Whenever an actively exploited Chromium zero-day drops, rebuild and redeploy your headless browser images immediately.

2026-12-22 Unlocks Dec 22
Day 23 Locked

Never Trust Client-Side RBAC Alone (IDOR Prevention)

Hiding a button in Angular or guarding a frontend route only improves UX. It isn't security. Every API endpoint must verify both role permissions and resource ownership on the server.

2026-12-23 Unlocks Dec 23
Day 24 Locked

The 5-Minute Holiday Freeze Security Checklist

Before logging off for the holidays: rotate shared deployment/API tokens, verify automated dependency & CVE alerts route to an active on-call channel, confirm production backups restore cleanly, and check for leftover debug rules.

2026-12-24 Unlocks Dec 24