Problem
Authentication scripts were fragmented across multiple single-purpose files (login-auth.js, signup-auth.js, account-auth.js), creating redundant boilerplate and lacking DOM XSS input sanitization and password strength scoring.
Current Behavior
User inputs in authentication forms were passed without sanitization, and password inputs lacked dynamic strength evaluation feedback.
Why This Improvement Is Needed
Centralizing authentication session logic and adding client-side input sanitization mitigates XSS security risks and enhances account security UX.
Proposed Solution
- Create
scripts/security-sanitizer.js providing HTML escaping, email sanitization, and password strength evaluation (0-4 scale).
- Create
scripts/auth-manager.js consolidating login, registration, profile state, and logout actions into a single session controller.
- Update
login.html, signup.html, account.html, and style.css.
- Delete legacy single-purpose scripts (
login-auth.js, signup-auth.js, account-auth.js) and Furnix-main/login.html.
Expected Outcome
- Unified authentication session management.
- Sanitized user input preventing XSS attacks.
- Dynamic password strength visualizer on registration form.
Additional Notes
Clean replacement of fragmented scripts with zero breaking changes.
Problem
Authentication scripts were fragmented across multiple single-purpose files (
login-auth.js,signup-auth.js,account-auth.js), creating redundant boilerplate and lacking DOM XSS input sanitization and password strength scoring.Current Behavior
User inputs in authentication forms were passed without sanitization, and password inputs lacked dynamic strength evaluation feedback.
Why This Improvement Is Needed
Centralizing authentication session logic and adding client-side input sanitization mitigates XSS security risks and enhances account security UX.
Proposed Solution
scripts/security-sanitizer.jsproviding HTML escaping, email sanitization, and password strength evaluation (0-4 scale).scripts/auth-manager.jsconsolidating login, registration, profile state, and logout actions into a single session controller.login.html,signup.html,account.html, andstyle.css.login-auth.js,signup-auth.js,account-auth.js) andFurnix-main/login.html.Expected Outcome
Additional Notes
Clean replacement of fragmented scripts with zero breaking changes.