From 26c7d69e8c30decc73374fcb41f0d711a1af3500 Mon Sep 17 00:00:00 2001 From: Kurt Zeilenga Date: Wed, 8 Dec 1999 06:44:22 +0000 Subject: [PATCH] Update for new password codes for MSVC5 --- build/main.dsw | 18 +++ clients/tools/ldappasswd.c | 3 +- include/lutil_md5.h | 2 + include/lutil_sha1.h | 1 + libraries/libldap/open.c | 66 ++++----- libraries/libldap/url.c | 4 +- libraries/liblutil/md5.c | 4 +- libraries/liblutil/passwd.c | 31 +++-- libraries/liblutil/passwd.dsp | 201 +++++++++++++++++++++++++++ libraries/liblutil/ptest.c | 54 +++++++ servers/slapd/back-ldbm/backldbm.dsp | 8 ++ servers/slapd/extended.c | 1 - servers/slapd/proto-slap.h | 2 +- 13 files changed, 341 insertions(+), 54 deletions(-) create mode 100644 libraries/liblutil/passwd.dsp create mode 100644 libraries/liblutil/ptest.c diff --git a/build/main.dsw b/build/main.dsw index 0dee32c0c0..b2361ab346 100644 --- a/build/main.dsw +++ b/build/main.dsw @@ -471,6 +471,24 @@ Package=<4> ############################################################################### +Project: "passwd"=..\libraries\liblutil\passwd.dsp - Package Owner=<4> + +Package=<5> +{{{ +}}} + +Package=<4> +{{{ + Begin Project Dependency + Project_Dep_Name liblber + End Project Dependency + Begin Project Dependency + Project_Dep_Name liblutil + End Project Dependency +}}} + +############################################################################### + Project: "setup"=..\include\setup.dsp - Package Owner=<4> Package=<5> diff --git a/clients/tools/ldappasswd.c b/clients/tools/ldappasswd.c index c8337121ba..d87730bf98 100644 --- a/clients/tools/ldappasswd.c +++ b/clients/tools/ldappasswd.c @@ -51,13 +51,12 @@ main( int argc, char *argv[] ) char *ldaphost = NULL; char *newpw = NULL; int noupdates = 0; - int i, j; + int i; int ldapport = 0; int debug = 0; int version = -1; int want_bindpw = 0; LDAP *ld; - struct berval cred; struct berval *bv = NULL; BerElement *ber; diff --git a/include/lutil_md5.h b/include/lutil_md5.h index bb96ef65a5..c94e12feed 100644 --- a/include/lutil_md5.h +++ b/include/lutil_md5.h @@ -24,6 +24,8 @@ LDAP_BEGIN_DECL important. ANSI guarantees that "unsigned long" will be big enough, and always using it seems to have few disadvantages. */ +#define LUTIL_MD5_BYTES 16 + struct lutil_MD5Context { ber_uint_t buf[4]; ber_uint_t bits[2]; diff --git a/include/lutil_sha1.h b/include/lutil_sha1.h index eaac88289d..573530da62 100644 --- a/include/lutil_sha1.h +++ b/include/lutil_sha1.h @@ -24,6 +24,7 @@ LDAP_BEGIN_DECL * SHA-1 in C * By Steve Reid */ +#define LUTIL_SHA1_BYTES 20 /* This code assumes char are 8-bits and uint32 are 32-bits */ typedef ac_uint4 uint32; diff --git a/libraries/libldap/open.c b/libraries/libldap/open.c index 13dd87ce84..fb2a140d5d 100644 --- a/libraries/libldap/open.c +++ b/libraries/libldap/open.c @@ -72,38 +72,6 @@ ldap_open( LDAP_CONST char *host, int port ) } -/* - * ldap_init - initialize the LDAP library. A magic cookie to be used for - * future communication is returned on success, NULL on failure. - * "host" may be a space-separated list of hosts or IP addresses - * - * Example: - * LDAP *ld; - * ld = ldap_open( host, port ); - */ -LDAP * -ldap_init( LDAP_CONST char *defhost, int defport ) -{ - LDAP *ld; - int rc; - - rc = ldap_create(&ld); - if ( rc != LDAP_SUCCESS ) - return NULL; - - if (defport != 0) - ld->ld_options.ldo_defport = defport; - - if (defhost != NULL) { - rc = ldap_set_option(ld, LDAP_OPT_HOST_NAME, defhost); - if ( rc != LDAP_SUCCESS ) { - ldap_ld_free(ld, 1, NULL, NULL); - return NULL; - } - } - - return( ld ); -} int ldap_create( LDAP **ldp ) @@ -202,6 +170,40 @@ ldap_create( LDAP **ldp ) return LDAP_SUCCESS; } +/* + * ldap_init - initialize the LDAP library. A magic cookie to be used for + * future communication is returned on success, NULL on failure. + * "host" may be a space-separated list of hosts or IP addresses + * + * Example: + * LDAP *ld; + * ld = ldap_open( host, port ); + */ +LDAP * +ldap_init( LDAP_CONST char *defhost, int defport ) +{ + LDAP *ld; + int rc; + + rc = ldap_create(&ld); + if ( rc != LDAP_SUCCESS ) + return NULL; + + if (defport != 0) + ld->ld_options.ldo_defport = defport; + + if (defhost != NULL) { + rc = ldap_set_option(ld, LDAP_OPT_HOST_NAME, defhost); + if ( rc != LDAP_SUCCESS ) { + ldap_ld_free(ld, 1, NULL, NULL); + return NULL; + } + } + + return( ld ); +} + + int ldap_initialize( LDAP **ldp, LDAP_CONST char *url ) { diff --git a/libraries/libldap/url.c b/libraries/libldap/url.c index 981ed25617..551892f009 100644 --- a/libraries/libldap/url.c +++ b/libraries/libldap/url.c @@ -580,7 +580,7 @@ char * ldap_url_list2hosts (LDAPURLDesc *ludlist) { LDAPURLDesc *ludp; - int size, len; + int size; char *s, *p, buf[32]; /* big enough to hold a long decimal # (overkill) */ if (ludlist == NULL) @@ -615,7 +615,7 @@ char * ldap_url_list2urls (LDAPURLDesc *ludlist) { LDAPURLDesc *ludp; - int size, len; + int size; char *s, *p, buf[32]; /* big enough to hold a long decimal # (overkill) */ if (ludlist == NULL) diff --git a/libraries/liblutil/md5.c b/libraries/liblutil/md5.c index e1d316a459..484590ad7d 100644 --- a/libraries/liblutil/md5.c +++ b/libraries/liblutil/md5.c @@ -297,7 +297,7 @@ int main (int argc, char **argv ) { struct lutil_MD5Context context; - unsigned char checksum[16]; + unsigned char checksum[LUTIL_MD5_BYTES]; int i; int j; @@ -312,7 +312,7 @@ main (int argc, char **argv ) lutil_MD5Init (&context); lutil_MD5Update (&context, argv[j], strlen (argv[j])); lutil_MD5Final (checksum, &context); - for (i = 0; i < 16; i++) + for (i = 0; i < LUTIL_MD5_BYTES; i++) { printf ("%02x", (unsigned int) checksum[i]); } diff --git a/libraries/liblutil/passwd.c b/libraries/liblutil/passwd.c index 89ae997be9..e8e406b67b 100644 --- a/libraries/liblutil/passwd.c +++ b/libraries/liblutil/passwd.c @@ -15,6 +15,7 @@ #include "portable.h" +#include #include #include @@ -251,7 +252,7 @@ static char * pw_string64( const unsigned char *salt, size_t saltlen ) { int rc; - char *string = NULL; + char *string; size_t b64len; size_t len = hashlen + saltlen; char *b64; @@ -301,17 +302,19 @@ static int chk_ssha1( const char* cred ) { lutil_SHA1_CTX SHA1context; - unsigned char SHA1digest[20]; + unsigned char SHA1digest[LUTIL_SHA1_BYTES]; int pw_len = strlen(passwd); int rc; unsigned char *orig_pass = NULL; /* base64 un-encode password */ - orig_pass = (unsigned char *) malloc( (size_t) ( + orig_pass = (unsigned char *) ber_memalloc( (size_t) ( LUTIL_BASE64_DECODE_LEN(pw_len) + 1) ); + if( orig_pass == NULL ) return -1; + if ((rc = lutil_b64_pton(passwd, orig_pass, pw_len)) < 0) { - free(orig_pass); + ber_memfree(orig_pass); return 1; } @@ -326,7 +329,7 @@ static int chk_ssha1( /* compare */ rc = memcmp((char *)orig_pass, (char *)SHA1digest, sizeof(SHA1digest)); - free(orig_pass); + ber_memfree(orig_pass); return rc; } @@ -336,7 +339,7 @@ static int chk_sha1( const char* cred ) { lutil_SHA1_CTX SHA1context; - unsigned char SHA1digest[20]; + unsigned char SHA1digest[LUTIL_SHA1_BYTES]; char base64digest[LUTIL_BASE64_ENCODE_LEN(sizeof(SHA1digest))+1]; lutil_SHA1Init(&SHA1context); @@ -359,17 +362,19 @@ static int chk_smd5( const char* cred ) { lutil_MD5_CTX MD5context; - unsigned char MD5digest[16]; + unsigned char MD5digest[LUTIL_MD5_BYTES]; int pw_len = strlen(passwd); int rc; unsigned char *orig_pass = NULL; /* base64 un-encode password */ - orig_pass = (unsigned char *) malloc( (size_t) ( + orig_pass = (unsigned char *) ber_memalloc( (size_t) ( LUTIL_BASE64_DECODE_LEN(pw_len) + 1) ); + if( orig_pass == NULL ) return -1; + if ((rc = lutil_b64_pton(passwd, orig_pass, pw_len)) < 0) { - free(orig_pass); + ber_memfree(orig_pass); return 1; } @@ -384,7 +389,7 @@ static int chk_smd5( /* compare */ rc = memcmp((char *)orig_pass, (char *)MD5digest, sizeof(MD5digest)); - free(orig_pass); + ber_memfree(orig_pass); return rc; } @@ -394,7 +399,7 @@ static int chk_md5( const char* cred ) { lutil_MD5_CTX MD5context; - unsigned char MD5digest[16]; + unsigned char MD5digest[LUTIL_MD5_BYTES]; char base64digest[LUTIL_BASE64_ENCODE_LEN(sizeof(MD5digest))+1]; lutil_MD5Init(&MD5context); @@ -454,7 +459,7 @@ static char *gen_ssha1( const char *passwd ) { lutil_SHA1_CTX SHA1context; - unsigned char SHA1digest[20]; + unsigned char SHA1digest[LUTIL_SHA1_BYTES]; unsigned char salt[4]; if( lutil_entropy( salt, sizeof(salt)) < 0 ) { @@ -505,10 +510,8 @@ static char *gen_smd5( lutil_MD5Init( &MD5context ); lutil_MD5Update( &MD5context, (const unsigned char *) passwd, strlen(passwd) ); - lutil_MD5Update( &MD5context, (const unsigned char *) salt, sizeof(salt) ); - lutil_MD5Final( MD5digest, &MD5context ); return pw_string64( scheme, diff --git a/libraries/liblutil/passwd.dsp b/libraries/liblutil/passwd.dsp new file mode 100644 index 0000000000..e5aa45b472 --- /dev/null +++ b/libraries/liblutil/passwd.dsp @@ -0,0 +1,201 @@ +# Microsoft Developer Studio Project File - Name="passwd" - Package Owner=<4> +# Microsoft Developer Studio Generated Build File, Format Version 5.00 +# ** DO NOT EDIT ** + +# TARGTYPE "Win32 (x86) Console Application" 0x0103 + +CFG=passwd - Win32 DLL Debug +!MESSAGE This is not a valid makefile. To build this project using NMAKE, +!MESSAGE use the Export Makefile command and run +!MESSAGE +!MESSAGE NMAKE /f "passwd.mak". +!MESSAGE +!MESSAGE You can specify a configuration when running NMAKE +!MESSAGE by defining the macro CFG on the command line. For example: +!MESSAGE +!MESSAGE NMAKE /f "passwd.mak" CFG="passwd - Win32 DLL Debug" +!MESSAGE +!MESSAGE Possible choices for configuration are: +!MESSAGE +!MESSAGE "passwd - Win32 Release" (based on "Win32 (x86) Console Application") +!MESSAGE "passwd - Win32 Debug" (based on "Win32 (x86) Console Application") +!MESSAGE "passwd - Win32 Single Debug" (based on\ + "Win32 (x86) Console Application") +!MESSAGE "passwd - Win32 Single Release" (based on\ + "Win32 (x86) Console Application") +!MESSAGE "passwd - Win32 DLL Debug" (based on\ + "Win32 (x86) Console Application") +!MESSAGE "passwd - Win32 DLL Release" (based on\ + "Win32 (x86) Console Application") +!MESSAGE + +# Begin Project +# PROP Scc_ProjName "" +# PROP Scc_LocalPath "" +CPP=cl.exe +RSC=rc.exe + +!IF "$(CFG)" == "passwd - Win32 Release" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 0 +# PROP BASE Output_Dir "Release" +# PROP BASE Intermediate_Dir "Release" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 0 +# PROP Output_Dir "..\..\Release" +# PROP Intermediate_Dir "..\..\Release\passwd" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c +# ADD CPP /nologo /MT /W3 /GX /O2 /I "..\..\include" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /YX /FD /c +# ADD BASE RSC /l 0x409 /d "NDEBUG" +# ADD RSC /l 0x409 /d "NDEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386 +# ADD LINK32 ws2_32.lib /nologo /subsystem:console /machine:I386 /libpath:"..\..\Release" + +!ELSEIF "$(CFG)" == "passwd - Win32 Debug" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 1 +# PROP BASE Output_Dir "passwd___" +# PROP BASE Intermediate_Dir "passwd___" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 1 +# PROP Output_Dir "..\..\Debug" +# PROP Intermediate_Dir "..\..\Debug\passwd" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c +# ADD CPP /nologo /MTd /W3 /Gm /GX /Zi /Od /I "..\..\include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR /YX /FD /c +# ADD BASE RSC /l 0x409 /d "_DEBUG" +# ADD RSC /l 0x409 /d "_DEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept +# ADD LINK32 ws2_32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"..\..\Debug" + +!ELSEIF "$(CFG)" == "passwd - Win32 Single Debug" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 1 +# PROP BASE Output_Dir "passwd___" +# PROP BASE Intermediate_Dir "passwd___" +# PROP BASE Ignore_Export_Lib 0 +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 1 +# PROP Output_Dir "..\..\SDebug" +# PROP Intermediate_Dir "..\..\SDebug\passwd" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /I "..\..\include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c +# ADD CPP /nologo /W3 /Gm /GX /Zi /Od /I "..\..\include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR /YX /FD /c +# ADD BASE RSC /l 0x409 /d "_DEBUG" +# ADD RSC /l 0x409 /d "_DEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 olber32.lib ws2_32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"..\Debug" +# ADD LINK32 ws2_32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"..\..\SDebug" + +!ELSEIF "$(CFG)" == "passwd - Win32 Single Release" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 0 +# PROP BASE Output_Dir "passwd__0" +# PROP BASE Intermediate_Dir "passwd__0" +# PROP BASE Ignore_Export_Lib 0 +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 0 +# PROP Output_Dir "..\..\SRelease" +# PROP Intermediate_Dir "..\..\SRelease\passwd" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +# ADD BASE CPP /nologo /W3 /GX /O2 /I "..\..\include" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c +# ADD CPP /nologo /W3 /GX /O2 /I "..\..\include" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /YX /FD /c +# ADD BASE RSC /l 0x409 /d "NDEBUG" +# ADD RSC /l 0x409 /d "NDEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 olber32.lib ws2_32.lib /nologo /subsystem:console /machine:I386 /libpath:"..\Release" +# ADD LINK32 ws2_32.lib /nologo /subsystem:console /machine:I386 /libpath:"..\..\SRelease" + +!ELSEIF "$(CFG)" == "passwd - Win32 DLL Debug" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 1 +# PROP BASE Output_Dir "passwd___" +# PROP BASE Intermediate_Dir "passwd___" +# PROP BASE Ignore_Export_Lib 0 +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 1 +# PROP Output_Dir "..\..\DLLDebug" +# PROP Intermediate_Dir "..\..\DLLDebug\passwd" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /Zi /Od /I "..\..\include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR /YX /FD /c +# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "..\..\include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR /YX /FD /c +# ADD BASE RSC /l 0x409 /d "_DEBUG" +# ADD RSC /l 0x409 /d "_DEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 ws2_32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"..\..\Debug" +# ADD LINK32 ws2_32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"..\..\Debug" + +!ELSEIF "$(CFG)" == "passwd - Win32 DLL Release" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 0 +# PROP BASE Output_Dir "passwd__0" +# PROP BASE Intermediate_Dir "passwd__0" +# PROP BASE Ignore_Export_Lib 0 +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 0 +# PROP Output_Dir "passwd__0" +# PROP Intermediate_Dir "passwd__0" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\..\include" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /YX /FD /c +# ADD CPP /nologo /MT /W3 /GX /O2 /I "..\..\include" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /YX /FD /c +# ADD BASE RSC /l 0x409 /d "NDEBUG" +# ADD RSC /l 0x409 /d "NDEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 ws2_32.lib /nologo /subsystem:console /machine:I386 /libpath:"..\..\Release" +# ADD LINK32 ws2_32.lib /nologo /subsystem:console /machine:I386 /libpath:"..\..\Release" + +!ENDIF + +# Begin Target + +# Name "passwd - Win32 Release" +# Name "passwd - Win32 Debug" +# Name "passwd - Win32 Single Debug" +# Name "passwd - Win32 Single Release" +# Name "passwd - Win32 DLL Debug" +# Name "passwd - Win32 DLL Release" +# Begin Source File + +SOURCE=.\ptest.c +# End Source File +# End Target +# End Project diff --git a/libraries/liblutil/ptest.c b/libraries/liblutil/ptest.c new file mode 100644 index 0000000000..d8d01fc63a --- /dev/null +++ b/libraries/liblutil/ptest.c @@ -0,0 +1,54 @@ +/* $OpenLDAP$ */ +/* + * Copyright 1998-1999 The OpenLDAP Foundation, All Rights Reserved. + * COPYING RESTRICTIONS APPLY, see COPYRIGHT file + */ + +#include "portable.h" + +#include + +#include + +#include +#include +#include +#include +#include + +#include "lutil.h" + +char *hash[] = { + "{SMD5}", "{SSHA}", + "{MD5}", "{SHA}", + NULL +}; + +struct pwtable { + char *pw; + size_t pwlen; +}; + +static const struct pwtable pw[] = { + { "secret", sizeof("secret")-1 }, + { "secret\0binary", sizeof("binary\0secret")-1 }, + { NULL } +}; + +int +main( int argc, char *argv[] ) +{ + int i, j, rc; + char *passwd; + + for( i= 0; hash[i]; i++ ) { + for( j = 0; pw[j].pw; j++ ) { + passwd = lutil_passwd_generate( pw[j].pw, hash[i] ); + rc = lutil_passwd( passwd, pw[j].pw, NULL ); + + printf("%s (%d): %s (%d)\n", + pw[j].pw, pw[j].pwlen, passwd, rc ); + } + } + return EXIT_SUCCESS; +} \ No newline at end of file diff --git a/servers/slapd/back-ldbm/backldbm.dsp b/servers/slapd/back-ldbm/backldbm.dsp index fc62fba4b2..c7d136d3ab 100644 --- a/servers/slapd/back-ldbm/backldbm.dsp +++ b/servers/slapd/back-ldbm/backldbm.dsp @@ -180,6 +180,10 @@ SOURCE=.\entry.c # End Source File # Begin Source File +SOURCE=.\extended.c +# End Source File +# Begin Source File + SOURCE=.\external.h # End Source File # Begin Source File @@ -224,6 +228,10 @@ SOURCE=.\nextid.c # End Source File # Begin Source File +SOURCE=.\passwd.c +# End Source File +# Begin Source File + SOURCE=".\proto-back-ldbm.h" # End Source File # Begin Source File diff --git a/servers/slapd/extended.c b/servers/slapd/extended.c index 2abf5407f6..dd48d4bee2 100644 --- a/servers/slapd/extended.c +++ b/servers/slapd/extended.c @@ -160,7 +160,6 @@ load_extop( SLAP_EXTOP_MAIN_FN ext_main ) { extop_list_t *ext; - int rc; if( ext_oid == NULL || *ext_oid == '\0' ) return -1; if(!ext_main) return -1; diff --git a/servers/slapd/proto-slap.h b/servers/slapd/proto-slap.h index e2d2bd8c0c..a07804d754 100644 --- a/servers/slapd/proto-slap.h +++ b/servers/slapd/proto-slap.h @@ -485,7 +485,7 @@ LIBSLAPD_F (int) slap_passwd_check( struct berval *cred ); LIBSLAPD_F (struct berval *) slap_passwd_generate( struct berval *cred ); - +LIBSLAPD_F (int) slap_passwd_init( void ); /* * kerberos.c */ -- 2.39.5