]> git.sur5r.net Git - openldap/blobdiff - libraries/libldap/bind.c
(Partial) Sync with HEAD
[openldap] / libraries / libldap / bind.c
index f985b3b0d937f50deaf4d881896e7bb11b0215ce..32238a53d55b3681a20699ae437091b7ff192392 100644 (file)
@@ -1,13 +1,23 @@
+/* bind.c */
 /* $OpenLDAP$ */
-/*
- * Copyright 1998-2000 The OpenLDAP Foundation, All Rights Reserved.
- * COPYING RESTRICTIONS APPLY, see COPYRIGHT file
- */
-/*  Portions
- *  Copyright (c) 1990 Regents of the University of Michigan.
- *  All rights reserved.
+/* This work is part of OpenLDAP Software <http://www.openldap.org/>.
+ *
+ * Copyright 1998-2003 The OpenLDAP Foundation.
+ * All rights reserved.
  *
- *  bind.c
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted only as authorized by the OpenLDAP
+ * Public License.
+ *
+ * A copy of this license is available in the file LICENSE in the
+ * top-level directory of the distribution or, alternatively, at
+ * <http://www.OpenLDAP.org/license.html>.
+ */
+/* Portions Copyright (c) 1990 Regents of the University of Michigan.
+ * All rights reserved.
+ */
+/* Portions Copyright (C) The Internet Society (1997)
+ * ASN.1 fragments are from RFC 2251; see RFC for full legal notices.
  */
 
 /*
@@ -42,7 +52,7 @@
 #include <ac/time.h>
 
 #include "ldap-int.h"
-
+#include "ldap_log.h"
 
 /*
  * ldap_bind - bind to the ldap server (and X.500).  The dn and password
 int
 ldap_bind( LDAP *ld, LDAP_CONST char *dn, LDAP_CONST char *passwd, int authmethod )
 {
+#ifdef NEW_LOGGING
+       LDAP_LOG ( OPERATION, ENTRY, "ldap_bind\n", 0, 0, 0 );
+#else
        Debug( LDAP_DEBUG_TRACE, "ldap_bind\n", 0, 0, 0 );
+#endif
 
        switch ( authmethod ) {
        case LDAP_AUTH_SIMPLE:
@@ -105,7 +119,11 @@ ldap_bind_s(
        LDAP_CONST char *passwd,
        int authmethod )
 {
+#ifdef NEW_LOGGING
+       LDAP_LOG ( OPERATION, ENTRY, "ldap_bind_s\n", 0, 0, 0 );
+#else
        Debug( LDAP_DEBUG_TRACE, "ldap_bind_s\n", 0, 0, 0 );
+#endif
 
        switch ( authmethod ) {
        case LDAP_AUTH_SIMPLE: