lists.arthurdejong.org
RSS feed

Re: Using the initial letter in the home directory

[Date Prev][Date Next] [Thread Prev][Thread Next]

Re: Using the initial letter in the home directory



On Tue, 2016-05-24 at 21:46 +0200, Jakub Jindra wrote:
> Acording to manpage of nslcd.conf and "Attribute mapping expressions"
> and bash manpage "${parameter:offset:length}"
> I think that following example should work:
> map     passwd  homeDirectory  "/home/${sAMAccountName:0:1}/${sAMAccountName}"

Sadly it does not. nslcd only supports a very small subset of the ${}
syntax but patches are welcome.

This shouldn't be too difficult to implement. The code is in
common/expr.c in the parse_dollar_expression() function. I just pushed
a change that would make extending the parsing slightly easier.

Thanks,

-- 
-- arthur - arthur@arthurdejong.org - http://arthurdejong.org/ --
-- 
To unsubscribe send an email to
nss-pam-ldapd-users-unsubscribe@lists.arthurdejong.org or see
http://lists.arthurdejong.org/nss-pam-ldapd-users/