1
/* Licensed to the Apache Software Foundation (ASF) under one or more
2
* contributor license agreements. See the NOTICE file distributed with
3
* this work for additional information regarding copyright ownership.
4
* The ASF licenses this file to You under the Apache License, Version 2.0
5
* (the "License"); you may not use this file except in compliance with
6
* the License. You may obtain a copy of the License at
8
* http://www.apache.org/licenses/LICENSE-2.0
10
* Unless required by applicable law or agreed to in writing, software
11
* distributed under the License is distributed on an "AS IS" BASIS,
12
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
* See the License for the specific language governing permissions and
14
* limitations under the License.
18
* The APR LDAP rebind functions provide an implementation of
19
* a rebind procedure that can be used to allow clients to chase referrals,
20
* using the same credentials used to log in originally.
22
* Use of this implementation is optional.
24
* @file apr_ldap_rebind.h
25
* @brief Apache LDAP library
28
#ifndef APU_LDAP_REBIND_H
29
#define APU_LDAP_REBIND_H
32
* @addtogroup APR_Util_LDAP
41
* Handle the case when LDAP is enabled
46
* APR LDAP initialize rebind lock
48
* This function creates the lock for controlling access to the xref list..
49
* @param pool Pool to use when creating the xref_lock.
51
APU_DECLARE_LDAP(apr_status_t) apr_ldap_rebind_init(apr_pool_t *pool);
55
* APR LDAP rebind_add function
57
* This function creates a cross reference entry for the specified ldap
58
* connection. The rebind callback function will look up this ldap
59
* connection so it can retrieve the bindDN and bindPW for use in any
60
* binds while referrals are being chased.
62
* This function will add the callback to the LDAP handle passed in.
64
* A cleanup is registered within the pool provided to remove this
65
* entry when the pool is removed. Alternatively apr_ldap_rebind_remove()
66
* can be called to explicitly remove the entry at will.
68
* @param pool The pool to use
69
* @param ld The LDAP connectionhandle
70
* @param bindDN The bind DN to be used for any binds while chasing
71
* referrals on this ldap connection.
72
* @param bindPW The bind Password to be used for any binds while
73
* chasing referrals on this ldap connection.
75
APU_DECLARE_LDAP(apr_status_t) apr_ldap_rebind_add(apr_pool_t *pool,
81
* APR LDAP rebind_remove function
83
* This function removes the rebind cross reference entry for the
84
* specified ldap connection.
86
* If not explicitly removed, this function will be called automatically
87
* when the pool is cleaned up.
89
* @param ld The LDAP connectionhandle
91
APU_DECLARE_LDAP(apr_status_t) apr_ldap_rebind_remove(LDAP *ld);
93
#endif /* APR_HAS_LDAP */
97
#endif /* APU_LDAP_REBIND_H */