You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now, users can sign up and log in without confirming their email addresses. This can cause security and user problems, such as:
Fake sign-ups from bots or bad users.
Unauthorized access using fake or wrong email addresses.
Trouble recovering accounts if the email is incorrect.
Without email verification, there is no way to confirm if users own the email they provide, which can lead to security issues and make the platform harder to use.
Acceptance Criteria
A newly registered user receives an email verification link.
Users cannot access protected routes unless their email is verified.
Clicking the verification link marks the user as verified in the database.
An endpoint exists to resend the verification email if needed.
If a user tries to access a protected route without verification, they receive an appropriate error response.
Email verification should use Laravel's built-in MustVerifyEmail feature.
Add Email Verification for New Users
Description
Right now, users can sign up and log in without confirming their email addresses. This can cause security and user problems, such as:
Without email verification, there is no way to confirm if users own the email they provide, which can lead to security issues and make the platform harder to use.
Acceptance Criteria
MustVerifyEmail
feature.Expected Outcome
email_verified_at
column in theusers
table is updated after successful verification.Requirements
Routes Implemented
Send verification email (automatic on registration)
MustVerifyEmail
is implemented on theUser
model.Verify email (
GET /api/v1/auth/email/verify/{id}/{hash}
)Auth::routes(['verify' => true])
.email_verified_at
column.Resend verification email (
POST /api/v1/auth/email/verification-notification
)Protected routes using
email.verified
middleware:Email verification improves security, prevents fake registrations, and ensures reliable account recovery.
The text was updated successfully, but these errors were encountered: