This is a very important feature. This determines the security of our project.
Implement session validation in the backend.
When user makes a REST API call to the backend, validate the session before each call is executed.
If the user's session doesn't exist (if the user is not logged in), redirect them to login page.
When user enters thier username and password in the login page and submits it, validate the username + password combo. If its valid, set the session.
If the user's session is valid (if the user is logged in), let the controllers do thier job.
Implement a logout button in homepage that logs them out.
This is a very broad feature, and ther are many ways of implementing it.
Do some research, find examples and tutorials, feel free to ask questions about details.
This is a very important feature. This determines the security of our project.
This is a very broad feature, and ther are many ways of implementing it. Do some research, find examples and tutorials, feel free to ask questions about details.