Skip to content

Reset LOGIN_TIMEOUT countdown on each web request #6929

@koratfood

Description

@koratfood

NetBox version

v2.11.10

Feature type

Change to existing functionality

Proposed functionality

I would like to propose that we make LOGIN_TIMEOUT an inactivity timer (i.e. log out users who do not send any new requests before the timer runs out), instead of a "time since user last entered their credentials" timer which it currently is.

Based on a few simple web searches, I have found that this can be easily achieved by appending "SESSION_SAVE_EVERY_REQUEST = True" to settings.py (possibly via configuration.py and getattr to make it optional). Based on my own tests, this appears to make Netbox behave exactly as I prefer. However, I have no experience with Django, and I am not a developer. Thus, I am not sure whether this - should you find the change to be conceptually acceptable for Netbox - would be a sensible or acceptable implementation.

Use case

This would make it easier for admins to use a lower LOGIN_TIMEOUT value and thus log out inactive users, without the risk of bothering active users with re-authentication while they are actively working and navigating the UI.

Database changes

No response

External dependencies

No response

Metadata

Metadata

Assignees

Labels

status: acceptedThis issue has been accepted for implementationtype: featureIntroduction of new functionality to the application

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions