What problem does it solve? Building authentication and authorization correctly is error-prone: weak JWT validation, insecure token storage, and outdated OAuth flows expose applications to token theft, XSS, and CSRF attacks. This Skill guides the implementation of modern identity controls without forcing a stack migration. ## Core Features & Use Cases - OAuth 2.1 & PKCE Flows: Standardizes Authorization Code with PKCE for public and confidential clients, eliminating deprecated implicit grants. - JWT Verification: Enforces cryptographic signature checks with issuer, audience, and algorithm allowlist validation against JWKS endpoints. - Secure Credential Storage: Directs iOS tokens to Keychain and web sessions to HttpOnly/Secure/SameSite cookies via the BFF pattern, plus Passkey/WebAuthn support. - Use Case: When adding sign-in to a mobile app, use this Skill to design the Authorization Code with PKCE flow, store refresh tokens in the iOS Keychain, and verify JWTs correctly at the API layer. ## Quick Start Use the auth-and-identity-rules skill to review my JWT validation middleware and design a PKCE-based login flow for my app.