From f70cc4cdc188fd8bf9f8f84cb55d15c122e463dd Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Sat, 21 Jun 2003 00:45:03 +0000 Subject: This patch works towards to goal of common code shared between idmap_ldap and pdb_ldap. So far, it's just a function rename, so that the next patch can be a very simple matter of copying functions, without worrying about what changed in the process. Also removes the 'static' pointers for the rebind procedures, replacing them with a linked list of value/key lookups. (Only needed on older LDAP client libs) Andrew Bartlett (This used to be commit f93167a7e1c56157481a934d2225fe19786a3bff) --- source3/include/smbldap.h | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'source3/include') diff --git a/source3/include/smbldap.h b/source3/include/smbldap.h index 987206b450..31f8d33b88 100644 --- a/source3/include/smbldap.h +++ b/source3/include/smbldap.h @@ -92,6 +92,18 @@ typedef struct _attrib_map_entry { const char *name; } ATTRIB_MAP_ENTRY; + +struct smbldap_state { + LDAP *ldap_struct; + time_t last_ping; + /* retrive-once info */ + const char *uri; + char *bind_dn; + char *bind_secret; + + unsigned int num_failures; +}; + /* structures */ extern ATTRIB_MAP_ENTRY attrib_map_v22[]; @@ -109,8 +121,7 @@ const char* get_attr_key2string( ATTRIB_MAP_ENTRY table[], int key ); char** get_attr_list( ATTRIB_MAP_ENTRY table[] ); void free_attr_list( char **list ); BOOL fetch_ldap_pw(char **dn, char** pw); -void ldap_set_mod (LDAPMod *** modlist, int modop, const char *attribute, const char *value); - +void smbldap_set_mod (LDAPMod *** modlist, int modop, const char *attribute, const char *value); #endif /* _SMBLDAP_H */ -- cgit