Added session-time out and cleanup related to security.