Benjamin Kuit's mods.
authorLuke Leighton <lkcl@samba.org>
Fri, 5 Mar 1999 22:03:04 +0000 (22:03 +0000)
committerLuke Leighton <lkcl@samba.org>
Fri, 5 Mar 1999 22:03:04 +0000 (22:03 +0000)
(This used to be commit eb63fbdb68f1189593e68272e05d7ebf76652c4c)

source3/include/proto.h
source3/passdb/mysqlpass.c
source3/passdb/mysqlsampass.c

index f31d17884276ecf0a0981e8a4703fc0f8aa7e624..063bcc2c45dd8c922dec05b9a2b47d517dac5b2e 100644 (file)
@@ -1351,6 +1351,11 @@ int lp_defaultcase(int );
 int lp_minprintspace(int );
 int lp_printing(int );
 char lp_magicchar(int );
+char *lp_mysql_host(void);
+char *lp_mysql_user(void);
+char *lp_mysql_passfile(void);
+char *lp_mysql_db(void);
+char *lp_mysql_table(void);
 BOOL lp_add_home(char *pszHomename, int iDefaultService, char *pszHomedir);
 int lp_add_service(char *pszService, int iDefaultService);
 BOOL lp_add_printer(char *pszPrintername, int iDefaultService);
@@ -1396,6 +1401,32 @@ struct smb_passwd *ldap_getpw(void);
 BOOL ldap_allocaterid(uint32 *rid);
 struct smb_passdb_ops *ldap_initialise_password_db(void);
 
+/*The following definitions come from  passdb/mysqlpass.c  */
+
+void *mysql_startpwent( BOOL update );
+void mysql_endpwent( void *ptr );
+SMB_BIG_UINT mysql_getpwpos(void *vp);
+BOOL mysql_setpwpos(void *vp, SMB_BIG_UINT pos);
+struct smb_passwd *mysql_getsmbpwent(void *vp);
+struct smb_passwd *mysql_getsmbpwuid(uid_t uid);
+struct smb_passwd *mysql_getsmbpwnam(const char *unix_name);
+BOOL mysql_add_smbpwd_entry(struct smb_passwd *smb);
+BOOL mysql_mod_smbpwd_entry(struct smb_passwd *smb, BOOL override);
+struct smb_passdb_ops *mysql_initialise_password_db(void);
+
+/*The following definitions come from  passdb/mysqlsampass.c  */
+
+struct sam_passwd *mysql_getsampwent(void *vp);
+struct sam_passwd *mysql_getsampwrid(uint32 rid);
+struct sam_passwd *mysql_getsampwuid(uid_t uid);
+struct sam_passwd *mysql_getsampwntnam(const char *nt_name);
+struct sam_disp_info *mysql_getsamdispntnam(const char *nt_name);
+struct sam_disp_info *mysql_getsamdisprid(uint32 rid);
+struct sam_disp_info *mysql_getsamdispent(void *vp);
+BOOL mysql_add_sampwd_entry(struct sam_passwd *sam);
+BOOL mysql_mod_sampwd_entry(struct sam_passwd *sam, BOOL override);
+struct sam_passdb_ops *mysql_initialise_sam_password_db(void);
+
 /*The following definitions come from  passdb/nispass.c  */
 
 struct passdb_ops *nisplus_initialise_password_db(void);
index c27cf708a65b87ac1486e1f7bf4c522955eb9474..35c82651b7e4e8e45b0c60c374f39c706188c76b 100644 (file)
@@ -392,7 +392,7 @@ struct smb_passwd *mysql_getsmbpwent(void *vp)
        return (struct smb_passwd*)mysql_fill_smb_passwd( mysql_getpwent(vp) );
 }
 
-void *mysql_fetch_passwd( mysql_fill_func filler, char *where )
+void *mysql_fetch_passwd( void *(*filler)(MYSQL_ROW*), char *where )
 {
        void *retval;
        MYSQL handle;
@@ -442,7 +442,7 @@ void *mysql_fetch_passwd( mysql_fill_func filler, char *where )
        return retval;
 }
 
-void *mysql_getpwuid(mysql_fill_func filler, uid_t uid)
+void *mysql_getpwuid(void *(*filler)(MYSQL_ROW *), uid_t uid)
 {
        fstring where;
 
@@ -461,7 +461,7 @@ struct smb_passwd *mysql_getsmbpwuid(uid_t uid)
        return (struct smb_passwd *)mysql_getpwuid( mysql_fill_smb_passwd, uid );
 }
 
-void *mysql_getpwnam(mysql_fill_func filler, char *field, const char *name)
+void *mysql_getpwnam(void *(*filler)(MYSQL_ROW *), char *field, const char *name)
 {
        fstring where;
        char format[] = "%s='%s'";
index e39bd6163353e8de533a5023c3f58c3fc761cb28..4615591bfbe11fd545c9ebf448428eb77cd5338b 100644 (file)
@@ -25,6 +25,8 @@
 
 #include "includes.h"
 
+MYSQL_ROW *mysql_getpwent(void *vp);
+
 extern int DEBUGLEVEL;
 
 extern pstring samlogon_user;