idurar/idurar-erp-crm

User Authentication process

開放

#457 建立於 2023年9月6日

 (14 則留言) (0 個反應) (1 位負責人)JavaScript (1,036 個分叉)batch import
good first issue🔧 Backend

倉庫指標

星標
 (4,308 顆星)
PR 合併指標
 (30 天內沒有已合併 PR)

描述

The objective of this feature is to enhance the existing user authentication process in our application. This includes implementing user registration, login, and logout functionalities with a primary focus on the backend. Additionally, we aim to incorporate user role-based permissions and ensure the seamless sharing of context with the controller.

Tasks:

  1. User Registration: Create registration API endpoints. Implement validation for user registration data. Store user registration data securely in the database. (As default, the first user registration role will be as admin)

  2. User Login: Develop login API endpoints. Implement user authentication during login. Generate and manage user sessions.

  3. User Logout: Create a logout API endpoint. Ensure proper session termination and security measures. Role-based Permissions:

  4. Define user roles: Implement role-based authorization logic. Restrict access to certain functionalities based on user roles. roles: ["admin", "staff"]

  5. Sharing Context with Controller Design an effective mechanism for sharing user context with the controller. Ensure that the controller can access relevant user data as needed.

貢獻者指南