wulf-pulse/app/auth/2fa/page.tsx
root 9f912aed24 feat: add authentication, user management, and admin features
Added comprehensive authentication and authorization system:

Authentication System:
- Better Auth integration with session management
- Login/logout pages and API routes
- Middleware for route protection
- Auth utilities and client libraries

User Management:
- User list, detail, and invite pages
- User API endpoints (CRUD operations)
- Session management for users
- Profile settings page

Role-Based Access Control:
- Role management pages (list, create, edit)
- Permission system with granular controls
- Role assignment to users
- Role API endpoints

Admin Features:
- Audit log page for tracking system events
- Admin settings page
- Audit service for logging user actions

Additional Features:
- Quotes management pages and components
- SalesBldr API integration
- Email service for notifications

Configuration & Documentation:
- Updated docker-compose.yml
- MCP server configuration (mcp.json)
- CVE-2025-55182 security review documentation
- Standards guide and PRD documents
- Re-enabling authentication documentation

Database Migrations:
- 012: Auth tables (users, sessions, accounts, verifications)
- 013: Role tables (roles, permissions, role_permissions, user_roles)
- 014: Admin settings table

UI Updates:
- Updated dashboard layout
- Enhanced app layout with auth integration
2026-01-31 12:43:14 -05:00

39 lines
1.3 KiB
TypeScript

"use client";
import { Suspense } from "react";
import { useSearchParams } from "next/navigation";
import { TwoFactorForm } from "@/components/auth/two-factor-form";
import { Card, CardContent, CardDescription, CardHeader, CardTitle } from "@/components/ui/card";
import { ShieldCheck } from "lucide-react";
function TwoFactorContent() {
const searchParams = useSearchParams();
const callbackURL = searchParams.get("callbackURL") || "/";
return (
<Card className="border-0 shadow-2xl bg-white/95 dark:bg-slate-900/95 backdrop-blur">
<CardHeader className="space-y-1 text-center">
<div className="flex justify-center mb-4">
<div className="h-12 w-12 rounded-xl bg-gradient-to-br from-purple-600 to-blue-600 flex items-center justify-center">
<ShieldCheck className="h-6 w-6 text-white" />
</div>
</div>
<CardTitle className="text-2xl font-bold">Two-Factor Authentication</CardTitle>
<CardDescription>
Enter the 6-digit code from your authenticator app
</CardDescription>
</CardHeader>
<CardContent>
<TwoFactorForm callbackURL={callbackURL} />
</CardContent>
</Card>
);
}
export default function TwoFactorPage() {
return (
<Suspense fallback={<div>Loading...</div>}>
<TwoFactorContent />
</Suspense>
);
}