nss-pam-ldapd commit: r1803 - in nss-pam-ldapd: common tests
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
nss-pam-ldapd commit: r1803 - in nss-pam-ldapd: common tests
- From: Commits of the nss-pam-ldapd project <nss-pam-ldapd-commits [at] lists.arthurdejong.org>
- To: nss-pam-ldapd-commits [at] lists.arthurdejong.org
- Reply-to: nss-pam-ldapd-users [at] lists.arthurdejong.org
- Subject: nss-pam-ldapd commit: r1803 - in nss-pam-ldapd: common tests
- Date: Fri, 19 Oct 2012 22:34:22 +0200 (CEST)
Author: arthur
Date: Fri Oct 19 22:34:21 2012
New Revision: 1803
URL: http://arthurdejong.org/viewvc/nss-pam-ldapd?revision=1803&view=revision
Log:
allow attribute options in attribute mapping expressions
Modified:
nss-pam-ldapd/common/expr.c
nss-pam-ldapd/tests/test_expr.c
Modified: nss-pam-ldapd/common/expr.c
==============================================================================
--- nss-pam-ldapd/common/expr.c Sun Oct 14 23:07:34 2012 (r1802)
+++ nss-pam-ldapd/common/expr.c Fri Oct 19 22:34:21 2012 (r1803)
@@ -51,7 +51,7 @@
/* look for an alpha+alphanumeric* string */
if (!my_isalpha(str[*ptr]))
return NULL;
- while (my_isalphanum(str[*ptr]))
+ while (my_isalphanum(str[*ptr])||(str[*ptr]==';'))
{
if ((size_t)i>=buflen)
return NULL;
Modified: nss-pam-ldapd/tests/test_expr.c
==============================================================================
--- nss-pam-ldapd/tests/test_expr.c Sun Oct 14 23:07:34 2012 (r1802)
+++ nss-pam-ldapd/tests/test_expr.c Fri Oct 19 22:34:21 2012 (r1803)
@@ -126,6 +126,11 @@
assert(set_contains(set,"uidNumber"));
assert(set_contains(set,"uid"));
set_free(set);
+ /* a test with attribute options */
+ set=set_new();
+ assert(expr_vars("\"${homeDirectory;foo:-/home/something}\"",set)!=NULL);
+ assert(set_contains(set,"homeDirectory;foo"));
+ set_free(set);
}
/* the main program... */
--
To unsubscribe send an email to
nss-pam-ldapd-commits-unsubscribe@lists.arthurdejong.org or see
http://lists.arthurdejong.org/nss-pam-ldapd-commits/
- nss-pam-ldapd commit: r1803 - in nss-pam-ldapd: common tests,
Commits of the nss-pam-ldapd project