I am currently building an internal web application used in a factory/warehouse type location. The users will be sharing a single PC between several people, so we need to have a fairly short session timeout to stop people wandering off and leaving the application logged in where someone else can come to the PC and do something under the previous user's username.
The problem with this is a session can timeout while a user is currently entering information into a form, especially if they take a long time.
How would you deal with this in a user friendly manner?
– You can manually specified the timeout value in “second” for a particular session. HttpSession session = request. getSession(); session. setMaxInactiveInterval(20*60);
To prevent a session timeout, you must interact with the workbook. This might include navigation around the workbook, sorting, filtering, or any other activity that you do with the elements of the workbook. When the server detects user interaction with the workbook, it keeps the session active.
The Session timeout defines an action window time for a user, this window represents the time in which an attacker can try to steal and use a existing user session… For this, it's best practices to : Set session timeout to the minimal value possible depending on the context of the application.
Since HTTP and Web Server both are stateless, the only way to maintain a session is when some unique information about the session (session id) is passed between server and client in every request and response. There are several ways through which we can provide unique identifier in request and response.
Keep the server informed about the fact that the user is actively entering information. For instance send a message to the server if the user presses the TAB key or clicks with a mouse on a field. The final solution is up to you.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With