mirror of
https://github.com/apache/httpd.git
synced 2025-08-08 15:02:10 +03:00
Remove the hardcoded size limit parameter for ldap_search_ext_s
and replace it with an APR_ defined value that is set according to the LDAP SDK being used. Submitted by: David Jones <oscaremma gmail com> git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@517788 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
@@ -52,8 +52,13 @@
|
|||||||
#define LDAP_CA_TYPE_BASE64 2
|
#define LDAP_CA_TYPE_BASE64 2
|
||||||
#define LDAP_CA_TYPE_CERT7_DB 3
|
#define LDAP_CA_TYPE_CERT7_DB 3
|
||||||
|
|
||||||
#ifndef LDAP_NO_LIMIT
|
/* Default define for ldap functions that need a SIZELIMIT but
|
||||||
#define LDAP_NO_LIMIT -1
|
* do not have the define
|
||||||
|
* XXX This should be removed once a supporting #define is
|
||||||
|
* released through APR-Util.
|
||||||
|
*/
|
||||||
|
#ifndef APR_LDAP_SIZELIMIT
|
||||||
|
#define APR_LDAP_SIZELIMIT -1
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
module AP_MODULE_DECLARE_DATA ldap_module;
|
module AP_MODULE_DECLARE_DATA ldap_module;
|
||||||
@@ -660,7 +665,7 @@ start_over:
|
|||||||
/* search for reqdn */
|
/* search for reqdn */
|
||||||
if ((result = ldap_search_ext_s(ldc->ldap, (char *)reqdn, LDAP_SCOPE_BASE,
|
if ((result = ldap_search_ext_s(ldc->ldap, (char *)reqdn, LDAP_SCOPE_BASE,
|
||||||
"(objectclass=*)", NULL, 1,
|
"(objectclass=*)", NULL, 1,
|
||||||
NULL, NULL, NULL, LDAP_NO_LIMIT, &res))
|
NULL, NULL, NULL, APR_LDAP_SIZELIMIT, &res))
|
||||||
== LDAP_SERVER_DOWN)
|
== LDAP_SERVER_DOWN)
|
||||||
{
|
{
|
||||||
ldc->reason = "DN Comparison ldap_search_ext_s() "
|
ldc->reason = "DN Comparison ldap_search_ext_s() "
|
||||||
@@ -938,7 +943,7 @@ start_over:
|
|||||||
if ((result = ldap_search_ext_s(ldc->ldap,
|
if ((result = ldap_search_ext_s(ldc->ldap,
|
||||||
(char *)basedn, scope,
|
(char *)basedn, scope,
|
||||||
(char *)filter, attrs, 0,
|
(char *)filter, attrs, 0,
|
||||||
NULL, NULL, NULL, LDAP_NO_LIMIT, &res))
|
NULL, NULL, NULL, APR_LDAP_SIZELIMIT, &res))
|
||||||
== LDAP_SERVER_DOWN)
|
== LDAP_SERVER_DOWN)
|
||||||
{
|
{
|
||||||
ldc->reason = "ldap_search_ext_s() for user failed with server down";
|
ldc->reason = "ldap_search_ext_s() for user failed with server down";
|
||||||
@@ -1178,7 +1183,7 @@ start_over:
|
|||||||
if ((result = ldap_search_ext_s(ldc->ldap,
|
if ((result = ldap_search_ext_s(ldc->ldap,
|
||||||
(char *)basedn, scope,
|
(char *)basedn, scope,
|
||||||
(char *)filter, attrs, 0,
|
(char *)filter, attrs, 0,
|
||||||
NULL, NULL, NULL, LDAP_NO_LIMIT, &res))
|
NULL, NULL, NULL, APR_LDAP_SIZELIMIT, &res))
|
||||||
== LDAP_SERVER_DOWN)
|
== LDAP_SERVER_DOWN)
|
||||||
{
|
{
|
||||||
ldc->reason = "ldap_search_ext_s() for user failed with server down";
|
ldc->reason = "ldap_search_ext_s() for user failed with server down";
|
||||||
|
Reference in New Issue
Block a user