]> git.sur5r.net Git - openldap/blobdiff - servers/slapd/back-perl/bind.c
fix ITS#5959 fix
[openldap] / servers / slapd / back-perl / bind.c
index 72e418746e0903360f2518168091e31ab9abe96b..d53dc150d8d4aa3127643f514c3b3fd89569564c 100644 (file)
@@ -1,7 +1,7 @@
 /* $OpenLDAP$ */
 /* This work is part of OpenLDAP Software <http://www.openldap.org/>.
  *
- * Copyright 1999-2006 The OpenLDAP Foundation.
+ * Copyright 1999-2009 The OpenLDAP Foundation.
  * Portions Copyright 1999 John C. Quillan.
  * Portions Copyright 2002 myinternet Limited.
  * All rights reserved.
@@ -32,6 +32,16 @@ perl_back_bind(
 
        PerlBackend *perl_back = (PerlBackend *) op->o_bd->be_private;
 
+       /* allow rootdn as a means to auth without the need to actually
+        * contact the proxied DSA */
+       switch ( be_rootdn_bind( op, rs ) ) {
+       case SLAP_CB_CONTINUE:
+               break;
+
+       default:
+               return rs->sr_err;
+       }
+
 #if defined(HAVE_WIN32_ASPERL) || defined(USE_ITHREADS)
        PERL_SET_CONTEXT( PERL_INTERPRETER );
 #endif