research-better-auth

Research authentication and authorization patterns for Next.js and Drizzle ORM.

1|Updated Sep 26, 2025
One-click install
npx skills add https://github.com/pascallammers/mylo-travel-concierge-v2 --skill research-better-auth
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: research-better-auth
Source: https://github.com/pascallammers/mylo-travel-concierge-v2/tree/main/.claude/skills/research-better-auth
Command: npx skills add https://github.com/pascallammers/mylo-travel-concierge-v2 --skill research-better-auth

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This skill helps developers understand and implement robust authentication and authorization patterns, ensuring secure and user-friendly access control in applications.

Core Features & Use Cases

  • Authentication Flows: Covers email/password, OAuth, magic links, and two-factor authentication.
  • Session Management: Details secure cookie configuration, expiration, and storage.
  • Authorization: Explains role-based access control (RBAC) and protected routes.
  • Use Case: Implement secure user sign-up, login, and password reset flows for a new web application.

Quick Start

Research Better Auth patterns for implementing secure user registration and login flows.

Frequently Asked Questions about research-better-auth

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I implement secure session management with httpOnly cookies in Next.js?

Secure session management in Next.js uses httpOnly cookies to prevent client-side access. This approach details secure cookie configuration, expiration policies, and storage strategies to protect user sessions.

What is the best way to set up role-based access control (RBAC) for protected routes?

Role-based access control (RBAC) protects routes by assigning permissions to user roles. Implementing RBAC involves defining roles, checking user authorization against protected routes, and restricting access based on assigned privileges.

How do I configure authentication flows like OAuth and magic links with Drizzle ORM?

Configuring authentication flows with Drizzle ORM involves integrating email/password, OAuth, and magic links. This setup guides implementing secure user sign-up, login, and password reset processes directly within your database layer.

Does Next.js provide built-in CSRF protection for authentication endpoints?

Next.js requires explicit CSRF protection implementation for authentication endpoints. Addressing this security requirement involves adding tokens or same-site cookie attributes to secure flows against cross-site request forgery attacks.

How does two-factor authentication integrate into a custom user login flow?

Two-factor authentication integrates into login flows by adding a secondary verification step. This mechanism enhances security beyond passwords by requiring additional verification before granting session access.

When should I implement custom authorization logic instead of using standard session management?

Custom authorization logic is necessary when standard session management cannot handle complex权限 requirements. Implement RBAC when your application needs granular access control and protected routes beyond basic user authentication.