]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Document keepalive
authorAlan T. DeKok <aland@freeradius.org>
Wed, 7 Sep 2011 10:59:21 +0000 (12:59 +0200)
committerAlan T. DeKok <aland@freeradius.org>
Wed, 7 Sep 2011 11:01:53 +0000 (13:01 +0200)
raddb/modules/ldap
src/modules/rlm_ldap/rlm_ldap.c

index 7c28632eafde38c39dd7bf47934ba295b4d9e502..c9520f47293796cf2d39b5938de93847b3b45832 100644 (file)
@@ -177,4 +177,21 @@ ldap {
         #  "password_header" configuration items have been removed.
         #  Since they were deprecated long ago, this change should not
         #  affect anyone.
+
+       #
+       #  Keepalive configuration.  This MAY NOT be supported by your
+       #  LDAP library.  If these configuration entries appear in the
+       #  output of "radiusd -X", then they are supported.  Otherwise,
+       #  they are unsupported, and changing them will do nothing.
+       #
+       keepalive {
+               # LDAP_OPT_X_KEEPALIVE_IDLE
+               idle = 60
+
+               # LDAP_OPT_X_KEEPALIVE_PROBES
+               probes = 3
+
+               # LDAP_OPT_X_KEEPALIVE_INTERVAL
+               interval = 3
+       }
 }
index c53293d4b3ba3fd38ca2f327b6740ec0ba384a79..a27a745ed4e6690ecddbd3ca6987d53565ef50d5 100644 (file)
@@ -190,6 +190,7 @@ typedef struct {
 /* The default setting for TLS Certificate Verification */
 #define TLS_DEFAULT_VERIFY "allow"
 
+#if defined(LDAP_OPT_X_KEEPALIVE_IDLE) || defined(LDAP_OPT_X_KEEPALIVE_PROBES) || defined (LDAP_OPT_ERROR_NUMBER)
 static CONF_PARSER keepalive_config[] = {
 #ifdef LDAP_OPT_X_KEEPALIVE_IDLE
        {"idle", PW_TYPE_INTEGER, offsetof(ldap_instance,keepalive_idle), NULL, "60"},
@@ -203,6 +204,7 @@ static CONF_PARSER keepalive_config[] = {
 
        { NULL, -1, 0, NULL, NULL }
 };
+#endf                          /* KEEPALIVE */
 
 static CONF_PARSER tls_config[] = {
        {"start_tls", PW_TYPE_BOOLEAN,
@@ -338,7 +340,10 @@ static const CONF_PARSER module_config[] = {
 
        {"set_auth_type", PW_TYPE_BOOLEAN, offsetof(ldap_instance,set_auth_type), NULL, "yes"},
 
+#if defined(LDAP_OPT_X_KEEPALIVE_IDLE) || defined(LDAP_OPT_X_KEEPALIVE_PROBES) || defined (LDAP_OPT_ERROR_NUMBER)
        { "keepalive", PW_TYPE_SUBSECTION, 0, NULL, (const void *) keepalive_config },
+#endif
+
        {NULL, -1, 0, NULL, NULL}
 };