What problem does it solve? Building a secure login system from scratch is error-prone: tokens stored in localStorage get stolen via XSS, refresh tokens without rotation allow indefinite session hijacking, and missing theft detection leaves compromised sessions invisible. This Skill provides a complete, security-hardened specification for stateless authentication with short-lived JWT access tokens and rotating refresh tokens. ## Core Features & Use Cases - Token Pair Generation: Issues 15-minute RS256-signed JWT access tokens alongside 30-day refresh tokens stored as SHA-256 hashes in the database. - Refresh Token Rotation with Theft Detection: Rotates tokens on every refresh and revokes the entire token family when reuse of a rotated token is detected. - Secure Cookie Handling: Delivers refresh tokens exclusively via HttpOnly, Secure, SameSite=Strict cookies scoped to the refresh endpoint. - Use Case: When implementing the login, logout, and social OAuth flow (Google, GitHub) for a multi-tenant SaaS platform, follow this Skill to get a complete step-by-step process, configuration table, and validation checklist. ## Quick Start Implement the login and token refresh flow for the platform following the JWT and rotating refresh token specification, including family revocation on token reuse.