]> git.sur5r.net Git - openldap/commitdiff
shortcut to allow restricting all operations
authorPierangelo Masarati <ando@openldap.org>
Thu, 15 Dec 2005 17:46:37 +0000 (17:46 +0000)
committerPierangelo Masarati <ando@openldap.org>
Thu, 15 Dec 2005 17:46:37 +0000 (17:46 +0000)
servers/slapd/bconfig.c
servers/slapd/slap.h

index f127993d35c24e2fd079e5dce76d4c72dbb08eb1..a080eb992b66c52fccd6812a7ec0d0d68b040622 100644 (file)
@@ -1947,7 +1947,7 @@ config_restrict(ConfigArgs *c) {
                { BER_BVC("modrdn"),            0 },
                { BER_BVC("delete"),            SLAP_RESTRICT_OP_DELETE },
                { BER_BVC("search"),            SLAP_RESTRICT_OP_SEARCH },
-               { BER_BVC("compare"),   SLAP_RESTRICT_OP_COMPARE },
+               { BER_BVC("compare"),           SLAP_RESTRICT_OP_COMPARE },
                { BER_BVC("read"),              SLAP_RESTRICT_OP_READS },
                { BER_BVC("write"),             SLAP_RESTRICT_OP_WRITES },
                { BER_BVC("extended"),  SLAP_RESTRICT_OP_EXTENDED },
@@ -1955,6 +1955,7 @@ config_restrict(ConfigArgs *c) {
                { BER_BVC("extended=" LDAP_EXOP_MODIFY_PASSWD ),        SLAP_RESTRICT_EXOP_MODIFY_PASSWD },
                { BER_BVC("extended=" LDAP_EXOP_X_WHO_AM_I ),           SLAP_RESTRICT_EXOP_WHOAMI },
                { BER_BVC("extended=" LDAP_EXOP_X_CANCEL ),             SLAP_RESTRICT_EXOP_CANCEL },
+               { BER_BVC("all"),               SLAP_RESTRICT_OP_ALL },
                { BER_BVNULL,   0 }
        };
 
index 1e310b067fd53a9ad838dd972df7d0b0e70359a5..febec4f4d98bfb5cd54f1b90f7df68f07e17de19 100644 (file)
@@ -1782,6 +1782,10 @@ struct slap_backend_db {
        | SLAP_RESTRICT_OP_DELETE \
        | SLAP_RESTRICT_OP_MODIFY \
        | SLAP_RESTRICT_OP_RENAME )
+#define SLAP_RESTRICT_OP_ALL \
+       ( SLAP_RESTRICT_OP_READS \
+       | SLAP_RESTRICT_OP_WRITES \
+       | SLAP_RESTRICT_OP_EXTENDED )
 
 #define SLAP_ALLOW_BIND_V2                     0x0001U /* LDAPv2 bind */
 #define SLAP_ALLOW_BIND_ANON_CRED      0x0002U /* cred should be empty */