From 4bc749a843e7c69b7dc6349c2084deeca69a8237 Mon Sep 17 00:00:00 2001 From: "gpt-engineer-app[bot]" <159125892+gpt-engineer-app[bot]@users.noreply.github.com> Date: Fri, 31 Oct 2025 13:49:18 +0000 Subject: [PATCH] Fix: Implement MFA security fix --- src/components/auth/MFAChallenge.tsx | 13 ++++- src/components/auth/MFAStepUpModal.tsx | 6 ++- src/pages/Auth.tsx | 71 +++++++++++++++++++++++--- 3 files changed, 80 insertions(+), 10 deletions(-) diff --git a/src/components/auth/MFAChallenge.tsx b/src/components/auth/MFAChallenge.tsx index 4e87922f..bd8d0db7 100644 --- a/src/components/auth/MFAChallenge.tsx +++ b/src/components/auth/MFAChallenge.tsx @@ -5,7 +5,8 @@ import { getErrorMessage } from '@/lib/errorHandler'; import { Button } from '@/components/ui/button'; import { Label } from '@/components/ui/label'; import { InputOTP, InputOTPGroup, InputOTPSlot } from '@/components/ui/input-otp'; -import { Shield } from 'lucide-react'; +import { Alert, AlertDescription, AlertTitle } from '@/components/ui/alert'; +import { Shield, AlertCircle } from 'lucide-react'; interface MFAChallengeProps { factorId: string; @@ -59,6 +60,14 @@ export function MFAChallenge({ factorId, onSuccess, onCancel }: MFAChallengeProp return (
+ + + Security Verification Required + + Cancelling will sign you out completely. Two-factor authentication must be completed to access your account. + + +

Two-Factor Authentication

@@ -96,7 +105,7 @@ export function MFAChallenge({ factorId, onSuccess, onCancel }: MFAChallengeProp className="flex-1" disabled={loading} > - Cancel + Cancel & Sign Out