From c0586f0f450ceb7c76901878e7cb9c7c4238d6b9 Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Mon, 26 Jan 2009 22:36:36 +0000 Subject: [PATCH] ITS#4359,#2615 add slapi_pw_find() --- servers/slapd/slapi/slapi_utils.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/servers/slapd/slapi/slapi_utils.c b/servers/slapd/slapi/slapi_utils.c index 3e1eb22693..ecf351d90d 100644 --- a/servers/slapd/slapi/slapi_utils.c +++ b/servers/slapd/slapi/slapi_utils.c @@ -26,6 +26,7 @@ #include #include #include +#include #include #include @@ -1820,9 +1821,16 @@ slapi_pw_find( struct berval **vals, struct berval *v ) { - /* - * FIXME: what's the point? - */ + int i; + + if( ( vals == NULL ) || ( v == NULL ) ) + return 1; + + for ( i = 0; vals[i] != NULL; i++ ) { + if ( !lutil_passwd( vals[i], v, NULL, NULL ) ) + return 0; + } + return 1; } -- 2.39.5