]> git.sur5r.net Git - openldap/blobdiff - servers/slapd/proto-slap.h
Use temporary AttributeDescriptions to prevent unbounded growth
[openldap] / servers / slapd / proto-slap.h
index 6728c9690789f3ff99f0198efadc7f2d551194e5..2640ca5fa8793c3dbe771f81e0c0531377a159f1 100644 (file)
@@ -31,6 +31,8 @@
 
 LDAP_BEGIN_DECL
 
+struct config_args_s;  /* config.h */
+
 /*
  * aci.c
  */
@@ -151,6 +153,10 @@ LDAP_SLAPD_F (int) slap_bv2undef_ad LDAP_P((
        const char **text,
        unsigned proxied ));
 
+LDAP_SLAPD_F (AttributeDescription *) slap_bv2tmp_ad LDAP_P((
+       struct berval *bv,
+       void *memctx ));
+
 LDAP_SLAPD_F (int) slap_ad_undef_promote LDAP_P((
        char *name,
        AttributeType *nat ));
@@ -293,7 +299,7 @@ LDAP_SLAPD_F (int) attr_destroy LDAP_P(( void ));
 LDAP_SLAPD_F (int) get_ava LDAP_P((
        Operation *op,
        BerElement *ber,
-       AttributeAssertion **ava,
+       Filter *f,
        unsigned usage,
        const char **text ));
 LDAP_SLAPD_F (void) ava_free LDAP_P((
@@ -316,11 +322,14 @@ LDAP_SLAPD_F (int) backend_startup_one LDAP_P((Backend *be));
 LDAP_SLAPD_F (int) backend_sync LDAP_P((Backend *be));
 LDAP_SLAPD_F (int) backend_shutdown LDAP_P((Backend *be));
 LDAP_SLAPD_F (int) backend_destroy LDAP_P((void));
+LDAP_SLAPD_F (void) backend_stopdown_one LDAP_P((BackendDB *bd ));
 LDAP_SLAPD_F (void) backend_destroy_one LDAP_P((BackendDB *bd, int dynamic));
 
 LDAP_SLAPD_F (BackendInfo *) backend_info LDAP_P(( const char *type ));
 LDAP_SLAPD_F (BackendDB *) backend_db_init LDAP_P(( const char *type,
-       BackendDB *be ));
+       BackendDB *be, int idx ));
+LDAP_SLAPD_F (void) backend_db_insert LDAP_P((BackendDB *bd, int idx));
+LDAP_SLAPD_F (void) backend_db_move LDAP_P((BackendDB *bd, int idx));
 
 LDAP_SLAPD_F (BackendDB *) select_backend LDAP_P((
        struct berval * dn,
@@ -408,7 +417,8 @@ LDAP_SLAPD_F (int) glue_sub_del( BackendDB *be );
  * backover.c
  */
 LDAP_SLAPD_F (int) overlay_register LDAP_P(( slap_overinst *on ));
-LDAP_SLAPD_F (int) overlay_config LDAP_P(( BackendDB *be, const char *ov ));
+LDAP_SLAPD_F (int) overlay_config LDAP_P(( BackendDB *be, const char *ov,
+       int idx, BackendInfo **res ));
 LDAP_SLAPD_F (void) overlay_destroy_one LDAP_P((
        BackendDB *be,
        slap_overinst *on ));
@@ -425,6 +435,10 @@ LDAP_SLAPD_F (int) overlay_op_walk LDAP_P((
        slap_operation_t which,
        slap_overinfo *oi,
        slap_overinst *on ));
+LDAP_SLAPD_F (void) overlay_insert LDAP_P((
+       BackendDB *be, slap_overinst *on, slap_overinst ***prev, int idx ));
+LDAP_SLAPD_F (void) overlay_move LDAP_P((
+       BackendDB *be, slap_overinst *on, int idx ));
 
 /*
  * bconfig.c
@@ -842,6 +856,7 @@ LDAP_SLAPD_F (int) register_certificate_map_function LDAP_P(( SLAP_CERT_MAP_FN *
  */
 LDAP_SLAPD_V (const Entry) slap_entry_root;
 
+LDAP_SLAPD_F (int) entry_init LDAP_P((void));
 LDAP_SLAPD_F (int) entry_destroy LDAP_P((void));
 
 LDAP_SLAPD_F (Entry *) str2entry LDAP_P(( char *s ));
@@ -852,12 +867,13 @@ LDAP_SLAPD_F (ber_len_t) entry_flatsize LDAP_P(( Entry *e, int norm ));
 LDAP_SLAPD_F (void) entry_partsize LDAP_P(( Entry *e, ber_len_t *len,
        int *nattrs, int *nvals, int norm ));
 
+LDAP_SLAPD_F (int) entry_header LDAP_P(( EntryHeader *eh ));
 #ifdef SLAP_ZONE_ALLOC
 LDAP_SLAPD_F (int) entry_decode LDAP_P((
-                                               struct berval *bv, Entry **e, void *ctx ));
+                                               EntryHeader *eh, Entry **e, void *ctx ));
 #else
 LDAP_SLAPD_F (int) entry_decode LDAP_P((
-                                               struct berval *bv, Entry **e ));
+                                               EntryHeader *eh, Entry **e ));
 #endif
 LDAP_SLAPD_F (int) entry_encode LDAP_P(( Entry *e, struct berval *bv ));
 
@@ -867,6 +883,7 @@ LDAP_SLAPD_F (int) entry_cmp LDAP_P(( Entry *a, Entry *b ));
 LDAP_SLAPD_F (int) entry_dn_cmp LDAP_P(( const void *v_a, const void *v_b ));
 LDAP_SLAPD_F (int) entry_id_cmp LDAP_P(( const void *v_a, const void *v_b ));
 LDAP_SLAPD_F (Entry *) entry_dup LDAP_P(( Entry *e ));
+LDAP_SLAPD_F (Entry *) entry_dup_bv LDAP_P(( Entry *e ));
 LDAP_SLAPD_F (Entry *) entry_alloc LDAP_P((void));
 LDAP_SLAPD_F (int) entry_prealloc LDAP_P((int num));
 
@@ -1085,6 +1102,7 @@ LDAP_SLAPD_F ( int ) slap_mods_no_repl_user_mod_check(
        size_t textlen );
 
 LDAP_SLAPD_F( int ) slap_mods_check(
+       Operation *op,
        Modifications *ml,
        const char **text,
        char *textbuf, size_t textlen, void *ctx );
@@ -1176,7 +1194,7 @@ LDAP_SLAPD_F (int) mr_usable_with_at( MatchingRule *mr,
 LDAP_SLAPD_F (int) get_mra LDAP_P((
        Operation *op,
        BerElement *ber,
-       MatchingRuleAssertion **mra,
+       Filter *f,
        const char **text ));
 LDAP_SLAPD_F (void) mra_free LDAP_P((
        Operation *op,
@@ -1261,14 +1279,14 @@ LDAP_SLAPD_F (void) oidm_destroy LDAP_P(( void ));
 LDAP_SLAPD_F (void) oidm_unparse LDAP_P((
        BerVarray *bva, OidMacro *start, OidMacro *end, int system ));
 LDAP_SLAPD_F (int) parse_oidm LDAP_P((
-       const char *fname, int lineno, int argc, char **argv, int user,
-       OidMacro **om ));
+       struct config_args_s *ca, int user, OidMacro **om ));
 
 /*
  * operation.c
  */
 LDAP_SLAPD_F (void) slap_op_init LDAP_P(( void ));
 LDAP_SLAPD_F (void) slap_op_destroy LDAP_P(( void ));
+LDAP_SLAPD_F (void) slap_op_groups_free LDAP_P(( Operation *op ));
 LDAP_SLAPD_F (void) slap_op_free LDAP_P(( Operation *op ));
 LDAP_SLAPD_F (void) slap_op_time LDAP_P(( time_t *t, int *n ));
 LDAP_SLAPD_F (Operation *) slap_op_alloc LDAP_P((
@@ -1398,12 +1416,15 @@ LDAP_SLAPD_V( const struct berval ) slap_dummy_bv;
 /*
  * root_dse.c
  */
+LDAP_SLAPD_F (int) root_dse_init LDAP_P(( void ));
+LDAP_SLAPD_F (int) root_dse_destroy LDAP_P(( void ));
+
 LDAP_SLAPD_F (int) root_dse_info LDAP_P((
        Connection *conn,
        Entry **e,
        const char **text ));
 
-LDAP_SLAPD_F (int) read_root_dse_file LDAP_P((
+LDAP_SLAPD_F (int) root_dse_read_file LDAP_P((
        const char *file));
 
 LDAP_SLAPD_F (int) slap_discover_feature LDAP_P((
@@ -1510,21 +1531,22 @@ LDAP_SLAPD_F (int) schema_info LDAP_P(( Entry **entry, const char **text ));
  */
 LDAP_SLAPD_F( int ) oc_check_allowed(
        AttributeType *type,
-       BerVarray oclist,
+       ObjectClass **socs,
        ObjectClass *sc );
 
 LDAP_SLAPD_F( int ) structural_class(
        BerVarray ocs,
-       struct berval *scbv,
        ObjectClass **sc,
+       ObjectClass ***socs,
        const char **text,
-       char *textbuf, size_t textlen );
+       char *textbuf, size_t textlen, void *ctx );
 
 LDAP_SLAPD_F( int ) entry_schema_check(
        Operation *op,
        Entry *e,
        Attribute *attrs,
        int manage,
+       int add_soc,
        const char** text,
        char *textbuf, size_t textlen );
 
@@ -1532,7 +1554,7 @@ LDAP_SLAPD_F( int ) mods_structural_class(
        Modifications *mods,
        struct berval *oc,
        const char** text,
-       char *textbuf, size_t textlen );
+       char *textbuf, size_t textlen, void *ctx );
 
 /*
  * schema_init.c
@@ -1568,14 +1590,11 @@ LDAP_SLAPD_F (int) slap_schema_check LDAP_P((void));
 LDAP_SLAPD_F( int ) slap_valid_descr( const char * );
 
 LDAP_SLAPD_F (int) parse_cr LDAP_P((
-       const char *fname, int lineno, char *line, char **argv,
-       ContentRule **scr ));
+       struct config_args_s *ca, ContentRule **scr ));
 LDAP_SLAPD_F (int) parse_oc LDAP_P((
-       const char *fname, int lineno, char *line, char **argv,
-       ObjectClass **soc, ObjectClass *prev ));
+       struct config_args_s *ca, ObjectClass **soc, ObjectClass *prev ));
 LDAP_SLAPD_F (int) parse_at LDAP_P((
-       const char *fname, int lineno, char *line, char **argv,
-       AttributeType **sat, AttributeType *prev ));
+       struct config_args_s *ca, AttributeType **sat, AttributeType *prev ));
 LDAP_SLAPD_F (char *) scherr2str LDAP_P((int code)) LDAP_GCCATTR((const));
 LDAP_SLAPD_F (int) dscompare LDAP_P(( const char *s1, const char *s2del,
        char delim ));