mirror of
https://github.com/ntop/ntopng.git
synced 2026-05-01 00:19:33 +00:00
Implements configurable session termination and midnight expire
This commit is contained in:
parent
98adc8a79f
commit
28e87d93bc
9 changed files with 58 additions and 7 deletions
|
|
@ -1006,6 +1006,25 @@ end
|
|||
|
||||
-- ================================================================================
|
||||
|
||||
local function printAuthDuration()
|
||||
print('<tr><th colspan=2 class="info">'..i18n("prefs.authentication_duration")..'</th></tr>')
|
||||
|
||||
prefsInputFieldPrefs(subpage_active.entries["authentication_duration"].title, subpage_active.entries["authentication_duration"].description,
|
||||
"ntopng.prefs.","auth_session_duration",
|
||||
prefs.auth_session_duration, "number", true, nil, nil,
|
||||
{min = 60 --[[ 1 minute --]], max = 86400 * 7 --[[ 7 days --]],
|
||||
tformat="mhd"})
|
||||
|
||||
prefsToggleButton(subpage_active, {
|
||||
field = "toggle_auth_session_midnight_expiration",
|
||||
default = "0",
|
||||
pref = "auth_session_midnight_expiration",
|
||||
})
|
||||
|
||||
end
|
||||
|
||||
-- ================================================================================
|
||||
|
||||
local function printLdapAuth()
|
||||
if not ntop.isPro() then return end
|
||||
|
||||
|
|
@ -1151,6 +1170,8 @@ function printAuthentication()
|
|||
|
||||
local entries = subpage_active.entries
|
||||
|
||||
printAuthDuration()
|
||||
|
||||
-- Note: order must correspond to evaluation order in Ntop.cpp
|
||||
if not entries.toggle_ldap_auth.hidden then
|
||||
printLdapAuth()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue