]>
Commit | Line | Data |
---|---|---|
3d551623 PG |
1 | diff --git a/CHANGELOG b/CHANGELOG |
2 | index 054d4df..ef549cf 100644 | |
3 | --- a/CHANGELOG | |
4 | +++ b/CHANGELOG | |
5 | @@ -22,6 +22,7 @@ | |
6 | - add LDAP schema discovery if no schema is configured. | |
7 | - add random selection as a master map entry option. | |
8 | - fix couple of edge case parse fails of timeout option. | |
9 | +- check for "*" when looking up wildcard in LDAP. | |
10 | ||
11 | 18/06/2007 autofs-5.0.2 | |
12 | ----------------------- | |
13 | diff --git a/modules/lookup_ldap.c b/modules/lookup_ldap.c | |
14 | index d5e666b..a7b315e 100644 | |
15 | --- a/modules/lookup_ldap.c | |
16 | +++ b/modules/lookup_ldap.c | |
17 | @@ -1500,7 +1500,7 @@ static int lookup_one(struct autofs_point *ap, | |
18 | *qKey = '/'; | |
19 | ||
20 | /* Build a query string. */ | |
21 | - l = strlen(class) + 2*strlen(entry) + strlen(qKey) + 29; | |
22 | + l = strlen(class) + 3*strlen(entry) + strlen(qKey) + 35; | |
23 | ||
24 | query = alloca(l); | |
25 | if (query == NULL) { | |
26 | @@ -1514,7 +1514,7 @@ static int lookup_one(struct autofs_point *ap, | |
27 | * whose entry is equal to qKey. | |
28 | */ | |
29 | ql = sprintf(query, | |
30 | - "(&(objectclass=%s)(|(%s=%s)(%s=/)))", class, entry, qKey, entry); | |
31 | + "(&(objectclass=%s)(|(%s=%s)(%s=/)(%s=\\2A)))", class, entry, qKey, entry, entry); | |
32 | if (ql >= l) { | |
33 | error(ap->logopt, | |
34 | MODPREFIX "error forming query string"); |