AOSSIE-Org / AOSSIE-Org/DebateAI

Issue: Incorrect Input Validation for Email/Password in Authentication

未关闭
#66 4 条评论 0 个 reaction 已指派 1 人 已被 @Aanchall26 认领 在 GitHub 查看
主要语言
TypeScript
星标
84
派生
198
平均合并
2 天 19 小时
30 天内合并 PR
30

描述

Observed Problem:

•On the login page of ArgueHub, an error message appears:
"The string did not match the expected pattern."
This suggests that the input validation for email or password is either too strict or incorrectly implemented.

Possible Causes & Fixes:

Email Regex Issue:
Your system might be using an overly restrictive regex pattern for email validation.
Example: If the backend only accepts example@domain.com but rejects subdomains (user@mail.co.in) or special characters, valid emails might fail.
Fix: Use a standard email regex.

•Frontend vs. Backend Validation Mismatch:

The frontend might allow certain email/password formats that the backend rejects.
Fix: Ensure that the same regex patterns and validation rules are enforced both in the frontend and backend.

•Unclear Error Messaging:
The generic message "The string did not match the expected pattern" does not tell the user exactly what is wrong.
Fix: Improve the error message to be specific, such as:
"Invalid email format. Use example@domain.com"
"Password must be at least 8 characters, include a number and a special symbol"

贡献指南

这个仓库没有索引到贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。