UC‑LOGIN‑01 — User Login
Use Case IDstrong>: UC‑LOGIN‑01 Use Case Namestrong> : User Login Modulestrong> : Login / AuthenticationPurpose
To allow a user to securely authenticate into the application using valid credentials, ensuring only authorized users gain access to protected features such as the Dashboard, Workout Logging, and Program Management.Primary Actor
| Actor | Description |
| App User | Any authenticated or unauthenticated user interacting with a major feature |
Stakeholders & Interests
| Stakeholder | Interest |
|---|---|
| User | Wants fast, secure access to their account. |
| System | Must validate credentials, enforce security rules, and create a secure session. |
| Security Team | Requires strong authentication, error handling, and protection against brute‑force attacks. |
| Product Owner | Wants a smooth login experience with clear error messaging. |
| Analytics Team | Needs to track successful logins and failed attempts. |
Preconditions
Postconditions
SuccessFailure
Trigger
User enters their email and password and selects Log In.Main Success Scenario (Basic Flow)
1. User navigates to the Login page. (BR‑Login‑01) 2. System displays the Login form with email and password fields. (BR‑Login‑01) 3. User enters email and password. (BR‑Login‑02) 4. System validates that both fields are populated. (BR‑Login‑02) 5. System validates that the email format is correct. (BR‑Login‑03) 6. System authenticates the credentials against stored values. (BR‑Login‑04) 7. System verifies the password using secure hashing. (BR‑Login‑05) 8. System checks whether the account is active (not locked, disabled, or inactive). (BR‑Login‑13) 9. System creates a secure session token. (BR‑Login‑08) 10. System stores the session token in an HTTP‑only cookie. (BR‑Login‑09) 11. System redirects the user to the Dashboard. (BR‑Login‑07) 12. System logs the successful login event. (Analytics requirement)Alternate Flows
A1 — Invalid Credentials- Step 6 fails.
- System displays an authentication error message.
- User remains on the Login page.
- Step 4 fails.
- System displays a “Required fields missing” message.
Exception Flows
E1 — Account Locked or Disabled- Step 8 fails.
- System displays a specific error message.
- User remains on the Login page.
- System detects repeated failed logins.
- System temporarily locks the account.
- System displays a lockout message.
- Step 6 or 7 fails due to backend or database issue.
- System displays a generic error message.
- User remains on the Login page.
Non‑Functional Requirements
- Security: All credentials must be transmitted over HTTPS. (BR‑Login‑15)
- Performance: Authentication must complete quickly.
- Accessibility: Login form must support keyboard navigation and screen readers. (SRS‑A11Y‑01)
- Usability: Error messages must be clear and actionable.
- Analytics: Login attempts (success/failure) must be logged.
Related UI Screens
- UIS‑LOGIN‑01 — Login Page
- UIS‑GLOBAL‑HEADER‑01
- UIS‑GLOBAL‑FOOTER‑01