#include "config.h" #include /* time.h */ #if TIME_WITH_SYS_TIME # include # include #else # if HAVE_SYS_TIME_H # include # else # include # endif #endif #include "errno.h" #include "scheme48.h" #include "ffi-tools/ffi-tools.h" #include #include static s48_value scsh_ldap_record_type = S48_FALSE; static s48_value scsh_ldapmessage_record_type = S48_FALSE; static s48_value scsh_ldapmod_record_type = S48_FALSE; static s48_value scsh_ldapapiinfo_record_type = S48_FALSE; static s48_value scsh_berelement_record_type = S48_FALSE; FFIT_MAKE_ENTER_RECORD_PROTOTYPE(scsh_enter_ldap, LDAP*); #define scsh_extract_ldap(x) \ ((LDAP *) \ s48_extract_integer(S48_RECORD_REF(x, 0))) FFIT_MAKE_ENTER_RECORD_PROTOTYPE(scsh_enter_ldapmessage, LDAPMessage*); #define scsh_extract_ldapmessage(x) \ ((LDAPMessage *) \ s48_extract_integer(S48_RECORD_REF(x, 0))) FFIT_MAKE_ENTER_RECORD_PROTOTYPE(scsh_enter_ldapmod, LDAPMod*); #define scsh_extract_ldapmod(x) \ ((LDAPMod *) \ s48_extract_integer(S48_RECORD_REF(x, 0))) FFIT_MAKE_ENTER_RECORD_PROTOTYPE(scsh_enter_ldapapiinfo, LDAPAPIInfo*); #define scsh_extract_ldapapiinfo(x) \ ((LDAPAPIInfo *) \ s48_extract_integer(S48_RECORD_REF(x, 0))) FFIT_MAKE_ENTER_RECORD_PROTOTYPE(scsh_enter_berelement, BerElement*); #define scsh_extract_berelement(x) \ ((BerElement *) \ s48_extract_integer(S48_RECORD_REF(x, 0))) /* conditions */ static s48_value condition_ldap_memory_alloc_error = S48_FALSE; static s48_value condition_ldap_feature_not_supported = S48_FALSE; static s48_value condition_ldap_read_only_option = S48_FALSE; #define RAISE_MEMORY_ALLOC_ERROR(FUNNAME) \ s48_call_scheme(S48_SHARED_BINDING_REF(raise_ldap_memory_alloc_error), \ 1, s48_enter_string(FUNNAME)); /* prototypes */ /* function body generated by ffi-tools */ void scsh_ldap_enter_ldap_constants(void); /* function body generated by ffi-tools */ void scsh_ldap_gc_protect_globals(void); LDAPMod** scsh_extract_ldapmod_vector(s48_value); void raise_ldap_memory_alloc_error(void); void raise_ldap_feature_not_supported(void); void raise_ldap_read_only_option(void); s48_value scsh_ldap_init(s48_value, s48_value); s48_value scsh_ldap_simple_bind_s(s48_value, s48_value, s48_value); s48_value scsh_ldap_sasl_bind_s(s48_value, s48_value, s48_value, s48_value, s48_value, s48_value, s48_value); s48_value scsh_ldap_unbind_s(s48_value); s48_value scsh_ldap_error_string(s48_value); s48_value scsh_ldap_result_error(s48_value, s48_value); s48_value scsh_ldap_memfree(s48_value); s48_value scsh_ldap_msgfree(s48_value); s48_value scsh_ldap_search_s(s48_value, s48_value, s48_value, s48_value, s48_value, s48_value); s48_value scsh_ldap_search_st(s48_value, s48_value, s48_value, s48_value, s48_value, s48_value, s48_value, s48_value); s48_value scsh_ldap_compare_s(s48_value, s48_value, s48_value, s48_value); s48_value scsh_ldap_count_entries(s48_value, s48_value); s48_value scsh_ldap_first_entry(s48_value, s48_value); s48_value scsh_ldap_next_entry(s48_value, s48_value); s48_value scsh_ldap_first_message(s48_value, s48_value); s48_value scsh_ldap_next_message(s48_value, s48_value); s48_value scsh_ldap_count_messages(s48_value, s48_value); s48_value scsh_ldap_first_reference(s48_value, s48_value); s48_value scsh_ldap_next_reference(s48_value, s48_value); s48_value scsh_ldap_count_references(s48_value, s48_value); s48_value scsh_ldap_msgtype(s48_value); s48_value scsh_ldap_msgid(s48_value); s48_value scsh_ldap_get_dn(s48_value, s48_value); s48_value scsh_ldap_explode_dn(s48_value, s48_value); s48_value scsh_ldap_explode_rdn(s48_value, s48_value); s48_value scsh_ldap_dn2ufn(s48_value); s48_value scsh_ldap_get_values(s48_value, s48_value, s48_value); s48_value scsh_ldap_modify(s48_value, s48_value, s48_value); s48_value scsh_ldap_add(s48_value, s48_value, s48_value); s48_value scsh_ldap_delete(s48_value, s48_value); s48_value scsh_ldap_abandon(s48_value, s48_value); s48_value scsh_ldap_get_set_option(s48_value, s48_value, s48_value, s48_value); s48_value scsh_ldapmod_create(s48_value, s48_value, s48_value); void scsh_init_ldap_bindings(void);