DijitallNotarer is a digital notarization platform using NestJS (backend), Next.js (frontend), and GraphQL APIs. It integrates LocalStack for AWS services, features a monorepo with Yarn workspaces, and includes CI/CD with GitHub Actions. Ideal for showcasing serverless and modern web tech stacks.
Now that the core functionality (user registration and OTP verification) is up and running, the next logical steps would focus on security, validation, and refining the user experience.
Here’s a high-level overview of the next steps you might want to consider:
1. Password Hashing
Why: Storing raw passwords in the database is insecure. Passwords should always be hashed before being stored.
What to Use: Use a strong hashing algorithm like bcrypt to hash passwords during user registration. This will ensure user passwords are secure in case of a database breach.
Next Step: Integrate password hashing before saving the user’s password in the database. During login or authentication, compare the hashed password with the stored hash.
2. Input Validation
Why: Currently, there might not be sufficient validation in place for user input fields. For example, validating if the email is correctly formatted, if the password meets complexity requirements, or if required fields like name and citizenship are filled.
What to Use: You can use class-validator with DTOs to enforce strong validation rules on the input fields. Add checks for required fields, email formats, and password strength.
Next Step: Implement robust validation for all input fields using NestJS validation pipes and DTOs.
3. Error Handling & Response Improvements
Why: Providing more informative and consistent error messages will enhance the user experience and make debugging easier. This includes more granular error handling for issues like database failures, validation errors, or OTP failures.
What to Use: Add more detailed error handling in the UserService and OtpService for different failure scenarios.
Next Step: Ensure all exceptions and errors are handled consistently and return useful messages to the client.
Summary of Next Steps:
Password Hashing – Ensure passwords are securely stored.
Input Validation – Validate all input fields for security and correctness.
Error Handling – Improve error handling for better user experience.
Now that the core functionality (user registration and OTP verification) is up and running, the next logical steps would focus on security, validation, and refining the user experience.
Here’s a high-level overview of the next steps you might want to consider:
1. Password Hashing
2. Input Validation
3. Error Handling & Response Improvements
UserService
andOtpService
for different failure scenarios.Summary of Next Steps: