]> git.sur5r.net Git - openldap/commitdiff
Don't publish version 2 if disallowed
authorKurt Zeilenga <kurt@openldap.org>
Thu, 31 Aug 2000 18:51:15 +0000 (18:51 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Thu, 31 Aug 2000 18:51:15 +0000 (18:51 +0000)
servers/slapd/root_dse.c

index 8a9cfc653cb22a1792163ada04d538962981797a..942364e0057d1ab42f18868ae64a0c2039633341 100644 (file)
@@ -82,6 +82,12 @@ root_dse_info(
 
        /* supportedLDAPVersion */
        for ( i=LDAP_VERSION_MIN; i<=LDAP_VERSION_MAX; i++ ) {
+               if (( global_disallows & SLAP_DISALLOW_BIND_V2 ) &&
+                       ( i < LDAP_VERSION3 ) )
+               {
+                       /* version 2 and lower are disallowed */
+                       continue;
+               }
                sprintf(buf,"%d",i);
                val.bv_val = buf;
                val.bv_len = strlen( val.bv_val );