]> granicus.if.org Git - apache/commitdiff
The Microsoft LDAP SDK escapes filters for us, stop util_ldap
authorGraham Leggett <minfrin@apache.org>
Fri, 21 May 2004 01:12:25 +0000 (01:12 +0000)
committerGraham Leggett <minfrin@apache.org>
Fri, 21 May 2004 01:12:25 +0000 (01:12 +0000)
from escaping filters twice when the backslash character is used.
PR: 24437
Obtained from:
Submitted by: Jess Holle <jessh@ptc.com>
Reviewed by: minfrin

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@103708 13f79535-47bb-0310-9956-ffa450edef68

CHANGES
modules/experimental/mod_auth_ldap.c

diff --git a/CHANGES b/CHANGES
index 26b754d955e1f21f5728d684dc72686a03a02f84..c2f844a4bd4660c42abd78c0643a79f703b7d888 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -2,6 +2,10 @@ Changes with Apache 2.1.0-dev
 
   [Remove entries to the current 2.0 section below, when backported]
 
+  *) The Microsoft LDAP SDK escapes filters for us, stop util_ldap
+     from escaping filters twice when the backslash character is used.
+     PR 24437 [Jess Holle <jessh@ptc.com>]
+
   *) Overhaul handling of LDAP error conditions, so that the util_ldap_*
      functions leave the connections in a sane state after errors have
      occurred. PR 27748, 17274, 17599, 18661, 21787, 24595, 24683, 27134,
index 400aea8da3a92849543bbfb368880c1794a06de6..d6f6dff435e0fe7d61901c33dde77b9a1b643091 100644 (file)
@@ -223,12 +223,16 @@ void mod_auth_ldap_build_filter(char *filtbuf,
     filtbuf_end = filtbuf + FILTER_LENGTH - 1;
     for (p = user, q=filtbuf + strlen(filtbuf);
          *p && q < filtbuf_end; *q++ = *p++) {
+#if APR_HAS_MICROSOFT_LDAPSDK
+        /* Note: The Microsoft SDK escapes for us, so is not necessary */
+#elif
         if (strchr("*()\\", *p) != NULL) {
             *q++ = '\\';
             if (q >= filtbuf_end) {
                break;
            }
         }
+#endif
     }
     *q = '\0';