3 * Copyright 1998-2000 The OpenLDAP Foundation, All Rights Reserved.
4 * COPYING RESTRICTIONS APPLY, see COPYRIGHT file
9 #include <ldap_cdefs.h>
13 LIBSLAPD_F( int ) schema_init_done;
14 #ifdef SLAPD_SCHEMA_NOT_COMPAT
15 LIBSLAPD_F( struct slap_internal_schema ) slap_schema;
17 LIBSLAPD_F (int) slap_str2ad LDAP_P((
19 AttributeDescription **ad,
22 LIBSLAPD_F (int) slap_bv2ad LDAP_P((
24 AttributeDescription **ad,
27 LIBSLAPD_F (AttributeDescription *) ad_dup LDAP_P((
28 AttributeDescription *desc ));
30 LIBSLAPD_F (void) ad_free LDAP_P((
31 AttributeDescription *desc,
34 #define ad_cmp(l,r) ( strcasecmp( \
35 (l)->ad_cname->bv_val, (r)->ad_cname->bv_val ))
37 LIBSLAPD_F (int) is_ad_subtype LDAP_P((
38 AttributeDescription *sub,
39 AttributeDescription *super ));
41 LIBSLAPD_F (int) ad_inlist LDAP_P((
42 AttributeDescription *desc,
45 #define ad_inlist(d,a) charray_inlist(a,d)
52 #if SLAPD_SCHEMA_NOT_COMPAT
53 LIBSLAPD_F (int) access_allowed LDAP_P((
54 Backend *be, Connection *conn, Operation *op,
55 Entry *e, AttributeDescription *desc, struct berval *val,
56 slap_access_t access ));
58 LIBSLAPD_F (int) access_allowed LDAP_P((
59 Backend *be, Connection *conn, Operation *op,
60 Entry *e, const char *attr, struct berval *val,
61 slap_access_t access ));
63 LIBSLAPD_F (int) acl_check_modlist LDAP_P((
64 Backend *be, Connection *conn, Operation *op,
65 Entry *e, Modifications *ml ));
67 LIBSLAPD_F (void) acl_append( AccessControl **l, AccessControl *a );
73 LIBSLAPD_F (void) parse_acl LDAP_P(( Backend *be,
74 const char *fname, int lineno,
75 int argc, char **argv ));
77 LIBSLAPD_F (char *) access2str LDAP_P(( slap_access_t access ));
78 LIBSLAPD_F (slap_access_t) str2access LDAP_P(( const char *str ));
80 #define ACCESSMASK_MAXLEN sizeof("unknown (+wrscan)")
81 LIBSLAPD_F (char *) accessmask2str LDAP_P(( slap_access_mask_t mask, char* ));
82 LIBSLAPD_F (slap_access_mask_t) str2accessmask LDAP_P(( const char *str ));
88 LIBSLAPD_F (void) at_config LDAP_P(( const char *fname, int lineno, int argc, char **argv ));
89 LIBSLAPD_F (AttributeType *) at_find LDAP_P(( const char *name ));
90 LIBSLAPD_F (int) at_find_in_list LDAP_P(( AttributeType *sat, AttributeType **list ));
91 LIBSLAPD_F (int) at_append_to_list LDAP_P(( AttributeType *sat, AttributeType ***listp ));
92 LIBSLAPD_F (int) at_delete_from_list LDAP_P(( int pos, AttributeType ***listp ));
93 LIBSLAPD_F (int) at_schema_info LDAP_P(( Entry *e ));
94 LIBSLAPD_F (int) at_add LDAP_P(( LDAP_ATTRIBUTE_TYPE *at, const char **err ));
96 #ifdef SLAPD_SCHEMA_NOT_COMPAT
97 LIBSLAPD_F (int) is_at_subtype LDAP_P((
99 AttributeType *super ));
101 LIBSLAPD_F (int) is_at_syntax LDAP_P((
105 # define at_canonical_name(at) ((at)->sat_cname)
107 LIBSLAPD_F (int) at_fake_if_needed LDAP_P(( const char *name ));
108 LIBSLAPD_F (char *) at_canonical_name LDAP_P(( const char * a_type ));
116 LIBSLAPD_F (void) attr_free LDAP_P(( Attribute *a ));
117 LIBSLAPD_F (Attribute *) attr_dup LDAP_P(( Attribute *a ));
119 #ifdef SLAPD_SCHEMA_NOT_COMPAT
120 LIBSLAPD_F (int) attr_merge LDAP_P(( Entry *e,
121 AttributeDescription *desc,
122 struct berval **vals ));
123 LIBSLAPD_F (Attribute *) attrs_find LDAP_P(( Attribute *a, AttributeDescription *desc ));
124 LIBSLAPD_F (Attribute *) attr_find LDAP_P(( Attribute *a, AttributeDescription *desc ));
125 LIBSLAPD_F (int) attr_delete LDAP_P(( Attribute **attrs, AttributeDescription *desc ));
127 LIBSLAPD_F (char *) attr_normalize LDAP_P(( char *s ));
128 LIBSLAPD_F (int) attr_merge LDAP_P(( Entry *e, const char *type,
129 struct berval **vals ));
130 LIBSLAPD_F (int) attr_merge_fast LDAP_P(( Entry *e, const char *type,
131 struct berval **vals, int nvals, int naddvals, int *maxvals,
133 LIBSLAPD_F (Attribute *) attr_find LDAP_P(( Attribute *a, const char *type ));
134 LIBSLAPD_F (int) attr_delete LDAP_P(( Attribute **attrs, const char *type ));
135 LIBSLAPD_F (int) attr_syntax LDAP_P(( const char *type ));
138 LIBSLAPD_F (void) attrs_free LDAP_P(( Attribute *a ));
139 LIBSLAPD_F (Attribute *) attrs_dup LDAP_P(( Attribute *a ));
145 #ifdef SLAPD_SCHEMA_NOT_COMPAT
146 LIBSLAPD_F (int) get_ava LDAP_P((
148 AttributeAssertion **ava,
150 const char **text ));
151 LIBSLAPD_F (void) ava_free LDAP_P((
152 AttributeAssertion *ava,
155 LIBSLAPD_F (int) get_ava LDAP_P((
158 const char **text ));
159 LIBSLAPD_F (void) ava_free LDAP_P(( Ava *ava, int freeit ));
166 LIBSLAPD_F (int) backend_init LDAP_P((void));
167 LIBSLAPD_F (int) backend_add LDAP_P((BackendInfo *aBackendInfo));
168 LIBSLAPD_F (int) backend_num LDAP_P((Backend *be));
169 LIBSLAPD_F (int) backend_startup LDAP_P((Backend *be));
170 LIBSLAPD_F (int) backend_shutdown LDAP_P((Backend *be));
171 LIBSLAPD_F (int) backend_destroy LDAP_P((void));
173 LIBSLAPD_F (BackendInfo *) backend_info LDAP_P(( const char *type ));
174 LIBSLAPD_F (BackendDB *) backend_db_init LDAP_P(( const char *type ));
176 LIBSLAPD_F (BackendDB *) select_backend LDAP_P(( const char * dn ));
178 LIBSLAPD_F (int) be_issuffix LDAP_P(( Backend *be, const char *suffix ));
179 LIBSLAPD_F (int) be_isroot LDAP_P(( Backend *be, const char *ndn ));
180 LIBSLAPD_F (int) be_isroot_pw LDAP_P(( Backend *be, const char *ndn, struct berval *cred ));
181 LIBSLAPD_F (char *) be_root_dn LDAP_P(( Backend *be ));
182 LIBSLAPD_F (int) be_entry_release_rw LDAP_P(( Backend *be, Entry *e, int rw ));
183 #define be_entry_release_r( be, e ) be_entry_release_rw( be, e, 0 )
184 #define be_entry_release_w( be, e ) be_entry_release_rw( be, e, 1 )
186 LIBSLAPD_F (int) backend_unbind LDAP_P((Connection *conn, Operation *op));
188 LIBSLAPD_F( int ) backend_check_controls LDAP_P((
192 const char **text ));
194 LIBSLAPD_F (int) backend_connection_init LDAP_P((Connection *conn));
195 LIBSLAPD_F (int) backend_connection_destroy LDAP_P((Connection *conn));
197 #ifdef SLAPD_SCHEMA_NOT_COMPAT
198 LIBSLAPD_F (int) backend_group LDAP_P((Backend *be,
202 ObjectClass *group_oc,
203 AttributeDescription *group_at
206 LIBSLAPD_F (int) backend_group LDAP_P((Backend *be,
210 const char *group_oc,
215 LIBSLAPD_F (Attribute *) backend_operational( Backend *, Entry * );
224 #define ch_malloc malloc
225 #define ch_realloc realloc
226 #define ch_calloc calloc
227 #define ch_strdup strdup
231 LIBSLAPD_F (void *) ch_malloc LDAP_P(( ber_len_t size ));
232 LIBSLAPD_F (void *) ch_realloc LDAP_P(( void *block, ber_len_t size ));
233 LIBSLAPD_F (void *) ch_calloc LDAP_P(( ber_len_t nelem, ber_len_t size ));
234 LIBSLAPD_F (char *) ch_strdup LDAP_P(( const char *string ));
235 LIBSLAPD_F (void) ch_free LDAP_P(( void * ));
247 LIBSLAPD_F (void) charray_add LDAP_P(( char ***a, const char *s ));
248 LIBSLAPD_F (void) charray_merge LDAP_P(( char ***a, char **s ));
249 LIBSLAPD_F (void) charray_free LDAP_P(( char **array ));
250 LIBSLAPD_F (int) charray_inlist LDAP_P(( char **a, const char *s ));
251 LIBSLAPD_F (char **) charray_dup LDAP_P(( char **a ));
252 LIBSLAPD_F (char **) str2charray LDAP_P(( const char *str, const char *brkstr ));
257 LIBSLAPD_F (int) get_ctrls LDAP_P((
262 LIBSLAPD_F (int) get_manageDSAit LDAP_P(( Operation *op ));
268 LIBSLAPD_F (int) read_config LDAP_P(( const char *fname ));
273 LIBSLAPD_F (int) connections_init LDAP_P((void));
274 LIBSLAPD_F (int) connections_shutdown LDAP_P((void));
275 LIBSLAPD_F (int) connections_destroy LDAP_P((void));
276 LIBSLAPD_F (int) connections_timeout_idle LDAP_P((time_t));
278 LIBSLAPD_F (long) connection_init LDAP_P((
282 const char* peername,
283 const char* sockname,
286 LIBSLAPD_F (void) connection_closing LDAP_P(( Connection *c ));
287 LIBSLAPD_F (int) connection_state_closing LDAP_P(( Connection *c ));
288 LIBSLAPD_F (const char *) connection_state2str LDAP_P(( int state )) LDAP_GCCATTR((const));
290 LIBSLAPD_F (int) connection_write LDAP_P((ber_socket_t s));
291 LIBSLAPD_F (int) connection_read LDAP_P((ber_socket_t s));
293 LIBSLAPD_F (unsigned long) connections_nextid(void);
295 LIBSLAPD_F (Connection *) connection_first LDAP_P((ber_socket_t *));
296 LIBSLAPD_F (Connection *) connection_next LDAP_P((Connection *, ber_socket_t *));
297 LIBSLAPD_F (void) connection_done LDAP_P((Connection *));
303 LIBSLAPD_F (char *) dn_validate LDAP_P(( char *dn ));
304 LIBSLAPD_F (char *) dn_normalize LDAP_P(( char *dn ));
305 LIBSLAPD_F (char *) dn_parent LDAP_P(( Backend *be, const char *dn ));
306 LIBSLAPD_F (char **) dn_subtree LDAP_P(( Backend *be, const char *dn ));
307 LIBSLAPD_F (char *) dn_rdn LDAP_P(( Backend *be, const char *dn ));
308 LIBSLAPD_F (int) dn_issuffix LDAP_P(( const char *dn, const char *suffix ));
309 LIBSLAPD_F (int) rdn_validate LDAP_P(( const char* str ));
310 LIBSLAPD_F (char *) rdn_attr_value LDAP_P(( const char * rdn ));
311 LIBSLAPD_F (char *) rdn_attr_type LDAP_P(( const char * rdn ));
313 LIBSLAPD_F (void) build_new_dn LDAP_P(( char ** new_dn,
316 const char * newrdn ));
321 LIBSLAPD_F (int) entry_destroy LDAP_P((void));
323 LIBSLAPD_F (Entry *) str2entry LDAP_P(( char *s ));
324 LIBSLAPD_F (char *) entry2str LDAP_P(( Entry *e, int *len ));
325 LIBSLAPD_F (void) entry_free LDAP_P(( Entry *e ));
327 LIBSLAPD_F (int) entry_cmp LDAP_P(( Entry *a, Entry *b ));
328 LIBSLAPD_F (int) entry_dn_cmp LDAP_P(( Entry *a, Entry *b ));
329 LIBSLAPD_F (int) entry_id_cmp LDAP_P(( Entry *a, Entry *b ));
335 #define SLAPD_EXTOP_GETVERSION 0
336 #define SLAPD_EXTOP_GETPROTO 1
337 #define SLAPD_EXTOP_GETAUTH 2
338 #define SLAPD_EXTOP_GETDN 3
339 #define SLAPD_EXTOP_GETCLIENT 4
341 typedef int (*SLAP_EXTOP_CALLBACK_FN) LDAP_P((
342 Connection *conn, Operation *op,
343 int msg, int arg, void *argp ));
345 typedef int (*SLAP_EXTOP_MAIN_FN) LDAP_P((
346 SLAP_EXTOP_CALLBACK_FN,
347 Connection *conn, Operation *op,
349 struct berval * reqdata,
351 struct berval ** rspdata,
352 LDAPControl *** rspctrls,
354 struct berval *** refs ));
356 typedef int (*SLAP_EXTOP_GETOID_FN) LDAP_P((
357 int index, char *oid, int blen ));
359 LIBSLAPD_F (int) load_extension LDAP_P((const void *module, const char *file_name));
360 LIBSLAPD_F (char *) get_supported_extension LDAP_P((int index));
362 LIBSLAPD_F (int) load_extop LDAP_P((
364 SLAP_EXTOP_MAIN_FN ext_main ));
366 LIBSLAPD_F (int) extops_init LDAP_P(( void ));
368 LIBSLAPD_F (int) extops_kill LDAP_P(( void ));
370 LIBSLAPD_F (char *) get_supported_extop LDAP_P((int index));
376 LIBSLAPD_F (int) get_filter LDAP_P((
381 const char **text ));
383 LIBSLAPD_F (void) filter_free LDAP_P(( Filter *f ));
384 LIBSLAPD_F (void) filter_print LDAP_P(( Filter *f ));
390 LIBSLAPD_F (int) test_filter LDAP_P((
391 Backend *be, Connection *conn, Operation *op, Entry *e, Filter *f ));
397 LIBSLAPD_F (FILE *) lock_fopen LDAP_P(( const char *fname, const char *type, FILE **lfp ));
398 LIBSLAPD_F (int) lock_fclose LDAP_P(( FILE *fp, FILE *lfp ));
403 * should be relocated to separate file
405 LIBSLAPD_F( void ) slap_mod_free LDAP_P(( Modification *mod, int freeit ));
406 LIBSLAPD_F( void ) slap_mods_free LDAP_P(( Modifications *mods ));
407 LIBSLAPD_F( void ) slap_modlist_free LDAP_P(( LDAPModList *ml ));
409 #ifdef SLAPD_SCHEMA_NOT_COMPAT
410 LIBSLAPD_F( int ) slap_modlist2mods(
413 Modifications **mods,
416 LIBSLAPD_F( int ) slap_mods_opattrs(
418 Modifications **modlist,
428 LIBSLAPD_F (int) module_init LDAP_P(( void ));
429 LIBSLAPD_F (int) module_kill LDAP_P(( void ));
431 LIBSLAPD_F (int) load_null_module(
432 const void *module, const char *file_name);
433 LIBSLAPD_F (int) load_extop_module(
434 const void *module, const char *file_name);
436 LIBSLAPD_F (int) module_load LDAP_P((
437 const char* file_name,
438 int argc, char *argv[] ));
439 LIBSLAPD_F (int) module_path LDAP_P(( const char* path ));
441 LIBSLAPD_F (void) *module_resolve LDAP_P((
442 const void *module, const char *name));
444 #endif /* SLAPD_MODULES */
449 LIBSLAPD_F (char *) supportedControls[];
451 LIBSLAPD_F (int) monitor_info LDAP_P((
452 Entry **entry, const char **text ));
458 LIBSLAPD_F (void) slap_op_free LDAP_P(( Operation *op ));
459 LIBSLAPD_F (Operation *) slap_op_alloc LDAP_P((
460 BerElement *ber, ber_int_t msgid,
461 ber_tag_t tag, ber_int_t id ));
463 LIBSLAPD_F (int) slap_op_add LDAP_P(( Operation **olist, Operation *op ));
464 LIBSLAPD_F (int) slap_op_remove LDAP_P(( Operation **olist, Operation *op ));
465 LIBSLAPD_F (Operation *) slap_op_pop LDAP_P(( Operation **olist ));
471 LIBSLAPD_F (char *) first_word LDAP_P(( char *s ));
472 LIBSLAPD_F (char *) next_word LDAP_P(( char *s ));
473 LIBSLAPD_F (char *) word_dup LDAP_P(( char *w ));
474 LIBSLAPD_F (char *) phonetic LDAP_P(( char *s ));
480 LIBSLAPD_F (void) replog LDAP_P(( Backend *be, Operation *op, char *dn, void *change ));
486 LIBSLAPD_F (struct berval **) get_entry_referrals LDAP_P((
487 Backend *be, Connection *conn, Operation *op,
490 LIBSLAPD_F (void) send_ldap_result LDAP_P((
491 Connection *conn, Operation *op,
492 ber_int_t err, const char *matched, const char *text,
493 struct berval **refs,
494 LDAPControl **ctrls ));
496 LIBSLAPD_F (void) send_ldap_sasl LDAP_P((
497 Connection *conn, Operation *op,
498 ber_int_t err, const char *matched,
500 struct berval **refs,
502 struct berval *cred ));
504 LIBSLAPD_F (void) send_ldap_disconnect LDAP_P((
505 Connection *conn, Operation *op,
506 ber_int_t err, const char *text ));
508 LIBSLAPD_F (void) send_ldap_extended LDAP_P((
509 Connection *conn, Operation *op,
510 ber_int_t err, const char *matched,
511 const char *text, struct berval **refs,
512 const char *rspoid, struct berval *rspdata,
513 LDAPControl **ctrls ));
515 LIBSLAPD_F (void) send_ldap_partial LDAP_P((
516 Connection *conn, Operation *op,
517 const char *rspoid, struct berval *rspdata,
518 LDAPControl **ctrls ));
520 LIBSLAPD_F (void) send_search_result LDAP_P((
521 Connection *conn, Operation *op,
522 ber_int_t err, const char *matched, const char *text,
523 struct berval **refs,
527 LIBSLAPD_F (int) send_search_reference LDAP_P((
528 Backend *be, Connection *conn, Operation *op,
529 Entry *e, struct berval **refs, int scope,
531 struct berval ***v2refs ));
533 LIBSLAPD_F (int) send_search_entry LDAP_P((
534 Backend *be, Connection *conn, Operation *op,
535 Entry *e, char **attrs, int attrsonly,
536 LDAPControl **ctrls ));
538 LIBSLAPD_F (int) str2result LDAP_P(( char *s,
539 int *code, char **matched, char **info ));
544 LIBSLAPD_F (char **) supportedSASLMechanisms;
546 LIBSLAPD_F (int) sasl_init(void);
547 LIBSLAPD_F (int) sasl_destroy(void);
548 LIBSLAPD_F (int) sasl_errldap LDAP_P(( int ));
549 LIBSLAPD_F (int) sasl_bind LDAP_P((
550 Connection *conn, Operation *op,
551 const char *dn, const char *ndn,
552 const char *mech, struct berval *cred,
556 LIBSLAPD_F (int) oc_schema_info( Entry *e );
559 LIBSLAPD_F (int) mr_schema_info( Entry *e );
562 LIBSLAPD_F (int) syn_schema_info( Entry *e );
568 #ifndef SLAPD_SCHEMA_NOT_COMPAT
569 LIBSLAPD_F (int) oc_check_op_attr LDAP_P(( const char *type ));
570 LIBSLAPD_F (int) oc_check_op_usermod_attr LDAP_P(( const char *type ));
571 LIBSLAPD_F (int) oc_check_op_no_usermod_attr LDAP_P(( const char *type ));
573 LIBSLAPD_F (ObjectClass *) oc_find LDAP_P((
574 const char *ocname));
576 LIBSLAPD_F (int) oc_add LDAP_P((
577 LDAP_OBJECT_CLASS *oc,
580 LIBSLAPD_F (int) is_object_subclass LDAP_P((
585 LIBSLAPD_F (Syntax *) syn_find LDAP_P((const char *synname));
586 LIBSLAPD_F (Syntax *) syn_find_desc LDAP_P((const char *syndesc, int *slen));
587 #ifdef SLAPD_BINARY_CONVERSION
588 LIBSLAPD_F (int) syn_add LDAP_P((
591 slap_syntax_validate_func *validate,
592 slap_syntax_transform_func *normalize,
593 slap_syntax_transform_func *pretty,
594 slap_syntax_transform_func *ber2str,
595 slap_syntax_transform_func *str2ber,
598 LIBSLAPD_F (int) syn_add LDAP_P((
601 slap_syntax_validate_func *validate,
602 slap_syntax_transform_func *normalize,
603 slap_syntax_transform_func *pretty,
607 LIBSLAPD_F (MatchingRule *) mr_find LDAP_P((const char *mrname));
608 LIBSLAPD_F (int) mr_add LDAP_P((LDAP_MATCHING_RULE *mr,
610 slap_mr_convert_func *convert,
611 slap_mr_normalize_func *normalize,
612 slap_mr_match_func *match,
613 slap_mr_indexer_func *indexer,
614 slap_mr_filter_func *filter,
617 LIBSLAPD_F (int) register_syntax LDAP_P((
620 slap_syntax_validate_func *validate,
621 slap_syntax_transform_func *ber2str,
622 slap_syntax_transform_func *str2ber ));
624 LIBSLAPD_F (int) register_matching_rule LDAP_P((
627 slap_mr_convert_func *convert,
628 slap_mr_normalize_func *normalize,
629 slap_mr_match_func *match,
630 slap_mr_indexer_func *indexer,
631 slap_mr_filter_func *filter ));
633 LIBSLAPD_F (int) schema_info LDAP_P(( Entry **entry, const char **text ));
635 #ifdef SLAPD_SCHEMA_NOT_COMPAT
636 LIBSLAPD_F (int) is_entry_objectclass LDAP_P((
637 Entry *, ObjectClass *oc ));
638 #define is_entry_alias(e) is_entry_objectclass((e), slap_schema.si_oc_alias)
639 #define is_entry_referral(e) is_entry_objectclass((e), slap_schema.si_oc_referral)
641 LIBSLAPD_F (int) is_entry_objectclass LDAP_P((
642 Entry *, const char* objectclass ));
643 #define is_entry_alias(e) is_entry_objectclass((e), "ALIAS")
644 #define is_entry_referral(e) is_entry_objectclass((e), "REFERRAL")
651 #ifdef SLAPD_SCHEMA_NOT_COMPAT
652 int oc_check_allowed(
654 struct berval **oclist );
656 LIBSLAPD_F (int) entry_schema_check LDAP_P((
657 Entry *e, Attribute *attrs,
658 const char** text ));
664 LIBSLAPD_F (int) schema_init LDAP_P((void));
665 LIBSLAPD_F (int) schema_prep LDAP_P((void));
672 LIBSLAPD_F (void) parse_oc_old LDAP_P(( Backend *be, const char *fname, int lineno, int argc, char **argv ));
673 LIBSLAPD_F (void) parse_oc LDAP_P(( const char *fname, int lineno, char *line, char **argv ));
674 LIBSLAPD_F (void) parse_at LDAP_P(( const char *fname, int lineno, char *line, char **argv ));
675 LIBSLAPD_F (void) parse_oidm LDAP_P(( const char *fname, int lineno, int argc, char **argv ));
676 LIBSLAPD_F (char *) scherr2str LDAP_P((int code)) LDAP_GCCATTR((const));
677 LIBSLAPD_F (int) dscompare LDAP_P(( const char *s1, const char *s2del, char delim ));
684 LIBSLAPD_F (int) starttls_extop LDAP_P((
685 SLAP_EXTOP_CALLBACK_FN,
686 Connection *conn, Operation *op,
688 struct berval * reqdata,
690 struct berval ** rspdata,
691 LDAPControl ***rspctrls,
693 struct berval *** refs ));
700 LIBSLAPD_F (Filter *) str2filter LDAP_P(( const char *str ));
705 LIBSLAPD_F (char *) suffix_alias LDAP_P(( Backend *be, char *ndn ));
710 #ifdef SLAPD_SCHEMA_NOT_COMPAT
711 LIBSLAPD_F (int) value_normalize LDAP_P((
712 AttributeDescription *ad,
716 const char ** text ));
717 LIBSLAPD_F (int) value_match LDAP_P((
719 AttributeDescription *ad,
723 const char ** text ));
724 LIBSLAPD_F (int) value_find LDAP_P((
725 AttributeDescription *ad,
726 struct berval **values,
727 struct berval *value ));
729 LIBSLAPD_F (int) value_add_fast LDAP_P(( struct berval ***vals, struct berval **addvals, int nvals, int naddvals, int *maxvals ));
730 LIBSLAPD_F (void) value_normalize LDAP_P(( char *s, int syntax ));
731 LIBSLAPD_F (int) value_cmp LDAP_P(( struct berval *v1, struct berval *v2, int syntax, int normalize ));
732 LIBSLAPD_F (int) value_find LDAP_P(( struct berval **vals, struct berval *v, int syntax, int normalize ));
734 LIBSLAPD_F (int) value_add LDAP_P(( struct berval ***vals, struct berval **addvals ));
739 #if defined(HAVE_PWD_H) && defined(HAVE_GRP_H)
740 LIBSLAPD_F (void) slap_init_user LDAP_P(( char *username, char *groupname ));
746 LIBSLAPD_F (int) passwd_extop LDAP_P((
747 SLAP_EXTOP_CALLBACK_FN,
748 Connection *conn, Operation *op,
750 struct berval * reqdata,
752 struct berval ** rspdata,
753 LDAPControl *** rspctrls,
755 struct berval *** refs ));
757 LIBSLAPD_F (int) slap_passwd_check(
759 struct berval *cred );
761 LIBSLAPD_F (struct berval *) slap_passwd_generate( void );
763 LIBSLAPD_F (struct berval *) slap_passwd_hash(
764 struct berval *cred );
766 LIBSLAPD_F (struct berval *) slap_passwd_return(
767 struct berval *cred );
769 LIBSLAPD_F (int) slap_passwd_parse(
770 struct berval *reqdata,
772 struct berval **oldpass,
773 struct berval **newpass,
779 #ifdef LDAP_API_FEATURE_X_OPENLDAP_V2_KBIND
780 extern char *ldap_srvtab;
781 LIBSLAPD_F (int) krbv4_ldap_auth();
788 LIBSLAPD_F (struct berval **) default_referral;
789 LIBSLAPD_F (char *) replogfile;
790 LIBSLAPD_F (const char) Versionstr[];
791 LIBSLAPD_F (int) active_threads;
792 LIBSLAPD_F (int) defsize;
793 LIBSLAPD_F (int) deftime;
794 LIBSLAPD_F (int) g_argc;
795 LIBSLAPD_F (slap_access_t) global_default_access;
796 LIBSLAPD_F (int) global_readonly;
797 LIBSLAPD_F (int) global_lastmod;
798 LIBSLAPD_F (int) global_idletimeout;
799 LIBSLAPD_F (int) global_schemacheck;
800 LIBSLAPD_F (char) *global_realm;
801 LIBSLAPD_F (char) *default_passwd_hash;
802 LIBSLAPD_F (int) lber_debug;
803 LIBSLAPD_F (int) ldap_syslog;
805 LIBSLAPD_F (ldap_pvt_thread_mutex_t) num_sent_mutex;
806 LIBSLAPD_F (long) num_bytes_sent;
807 LIBSLAPD_F (long) num_pdu_sent;
808 LIBSLAPD_F (long) num_entries_sent;
809 LIBSLAPD_F (long) num_refs_sent;
811 LIBSLAPD_F (ldap_pvt_thread_mutex_t) num_ops_mutex;
812 LIBSLAPD_F (long) num_ops_completed;
813 LIBSLAPD_F (long) num_ops_initiated;
815 LIBSLAPD_F (char *) slapd_pid_file;
816 LIBSLAPD_F (char *) slapd_args_file;
817 LIBSLAPD_F (char) **g_argv;
818 LIBSLAPD_F (time_t) starttime;
820 LIBSLAPD_F (time_t) slap_get_time LDAP_P((void));
822 LIBSLAPD_F (ldap_pvt_thread_mutex_t) active_threads_mutex;
823 LIBSLAPD_F (ldap_pvt_thread_cond_t) active_threads_cond;
825 LIBSLAPD_F (ldap_pvt_thread_mutex_t) entry2str_mutex;
826 LIBSLAPD_F (ldap_pvt_thread_mutex_t) replog_mutex;
829 LIBSLAPD_F (ldap_pvt_thread_mutex_t) crypt_mutex;
831 LIBSLAPD_F (ldap_pvt_thread_mutex_t) gmtime_mutex;
833 LIBSLAPD_F (AccessControl *) global_acl;
835 LIBSLAPD_F (int) slap_init LDAP_P((int mode, const char* name));
836 LIBSLAPD_F (int) slap_startup LDAP_P(( Backend *be ));
837 LIBSLAPD_F (int) slap_shutdown LDAP_P(( Backend *be ));
838 LIBSLAPD_F (int) slap_destroy LDAP_P((void));
842 LIBSLAPD_F (int) slapd_daemon_init( const char *urls );
843 LIBSLAPD_F (int) slapd_daemon_destroy(void);
844 LIBSLAPD_F (int) slapd_daemon(void);
846 LIBSLAPD_F (void) slapd_set_write LDAP_P((ber_socket_t s, int wake));
847 LIBSLAPD_F (void) slapd_clr_write LDAP_P((ber_socket_t s, int wake));
848 LIBSLAPD_F (void) slapd_set_read LDAP_P((ber_socket_t s, int wake));
849 LIBSLAPD_F (void) slapd_clr_read LDAP_P((ber_socket_t s, int wake));
851 LIBSLAPD_F (void) slapd_remove LDAP_P((ber_socket_t s, int wake));
853 LIBSLAPD_F (RETSIGTYPE) slap_sig_shutdown LDAP_P((int sig));
854 LIBSLAPD_F (RETSIGTYPE) slap_sig_wake LDAP_P((int sig));
856 LIBSLAPD_F (int) config_info LDAP_P((
857 Entry **e, const char **text ));
859 LIBSLAPD_F (int) root_dse_info LDAP_P((
860 Entry **e, const char **text ));
862 LIBSLAPD_F (int) do_abandon LDAP_P((Connection *conn, Operation *op));
863 LIBSLAPD_F (int) do_add LDAP_P((Connection *conn, Operation *op));
864 LIBSLAPD_F (int) do_bind LDAP_P((Connection *conn, Operation *op));
865 LIBSLAPD_F (int) do_compare LDAP_P((Connection *conn, Operation *op));
866 LIBSLAPD_F (int) do_delete LDAP_P((Connection *conn, Operation *op));
867 LIBSLAPD_F (int) do_modify LDAP_P((Connection *conn, Operation *op));
868 LIBSLAPD_F (int) do_modrdn LDAP_P((Connection *conn, Operation *op));
869 LIBSLAPD_F (int) do_search LDAP_P((Connection *conn, Operation *op));
870 LIBSLAPD_F (int) do_unbind LDAP_P((Connection *conn, Operation *op));
871 LIBSLAPD_F (int) do_extended LDAP_P((Connection *conn, Operation *op));
874 LIBSLAPD_F (ber_socket_t) dtblsize;
878 #endif /* _proto_slap */