[pmwiki-users] AuthUser - ldap - how to define custom groups
Thomas Gemperli
tom at arch.ethz.ch
Thu Feb 8 15:38:50 CST 2007
Hi
On 08.02.2007, at 18:49, Patrick R. Michaud wrote:
> On Thu, Feb 08, 2007 at 06:18:25PM +0100, Thomas Gemperli wrote:
>> Because I want to use existing ldap groups to assign edit rights I've
>> wrote a small piece of php code to get out group-memberships from our
>> LDAP. Well, this works also. config.php snippet:
>>
>> $AuthUser['@editors'] = array(get_ldap_values("cn=groups",
>> "(cn=aldapgroup)", array("memberUid")));
>> ...
>> Obviously the following statement in config.php does not work:
>> $AuthUser['@othereditors'] = array(get_ldap_values("cn=groups",
>> "(cn=anotherldapgroup)", array("memberUid")));
>
> What doesn't the @othereditors line work? If it works for @editors,
> it should work for @othereditors as well.
It does...
> One thing I will note is that any settings to the $AuthUser array
> need to be made *before* including the authuser.php script --
> the snippet you give shows it happening afterwards.
My snippet was cut&pasted from different places in config.php,
$AuthUser['@othereditors'] was below the authuser.php include.
Well, rtfm, sorry and thank you vey much!
Thomas
More information about the pmwiki-users
mailing list