diff --git a/DOCUMENTATION.md b/DOCUMENTATION.md index dc31d9b1..a5238bc6 100644 --- a/DOCUMENTATION.md +++ b/DOCUMENTATION.md @@ -814,7 +814,8 @@ Default: `none` ##### cache_logins -Cache successful/failed logins until expiration time +Cache successful/failed logins until expiration time. Enable this to avoid +overload of authentication backends. Default: `false` @@ -822,13 +823,13 @@ Default: `false` Expiration time of caching successful logins in seconds -Default: `5` +Default: `15` ##### cache_failed_logins_expiry Expiration time of caching failed logins in seconds -Default: `60` +Default: `90` ##### htpasswd_filename diff --git a/config b/config index 429cfca1..9ac082cf 100644 --- a/config +++ b/config @@ -62,11 +62,14 @@ # Value: none | htpasswd | remote_user | http_x_remote_user | ldap | denyall #type = none -# Cache successful logins for until expiration time +# Cache logins for until expiration time #cache_logins = false # Expiration time for caching successful logins in seconds -#cache_logins_expiry = 5 +#cache_successful_logins_expiry = 15 + +## Expiration time of caching failed logins in seconds +#cache_failed_logins_expiry = 90 # URI to the LDAP server #ldap_uri = ldap://localhost diff --git a/radicale/config.py b/radicale/config.py index f71f312b..b165345f 100644 --- a/radicale/config.py +++ b/radicale/config.py @@ -188,11 +188,11 @@ DEFAULT_CONFIG_SCHEMA: types.CONFIG_SCHEMA = OrderedDict([ "help": "cache successful/failed logins for until expiration time", "type": bool}), ("cache_successful_logins_expiry", { - "value": "5", + "value": "15", "help": "expiration time for caching successful logins in seconds", "type": int}), ("cache_failed_logins_expiry", { - "value": "60", + "value": "90", "help": "expiration time for caching failed logins in seconds", "type": int}), ("htpasswd_filename", {