We are working on the applications with frontend angular and backend dotnet core. We have to check during login, whether the same user has already been logged in or not..If yes, then it will intimate user like same User has already been signed in..Whenever I start looking for this solution across internet, I saw options like we can have some flag stored in db during user logged in as 1 , if again the same user tries to log in means it should intimate the second login user.But my doubt is during system failure like suddon powershutdown / session timeout how can we update the log in flag as 0 (i.e.,we are not able to logout properly during this time right?)
Any help will be appreciated... Thanks in Advance!!
The implementation will be a bit tricky
Note: Using this implementation if a second user tries to login he will not be able to login. If he is a valid user he can always reset using step 5. If the user reset then the previous user will not receive any new data and will be redirected to login page