I have one dynamic web application hosted locally on tomcat, I want to manage login for users. User should be able to login from only one browser.
Use case- If a user logs in from one browser (lets say chrome) with userId and password then at the same time if he/she tries to login from another browser (lets say firefox) then the session which is present is chrome (first browser) should be terminated and he/she remains logged in from second browser (firefox in our scenario) I have thinking of HttpSession with filter and ConcurrentHashMap but we have to maintain session id multiple times as well as has to remove when users gets logged out. Suggest anything if anyone knows any better approach.