Re: [exim] Replacing check_local_users with LDAP lookups

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Gavin Henry
Date:  
À: exim-users
Sujet: Re: [exim] Replacing check_local_users with LDAP lookups
<quote who="Stephen Gran">
> On Fri, Dec 22, 2006 at 03:18:01PM -0000, Gavin Henry said:
>> Dear all,
>>
>> The last thing left to covert all of Exim over to LDAP users is the
>> check_local_user part.
>>
>> We've got our Aliases sorted, but when we set a condition in the
>> local_user router, it can't get the gid and uid of the user, as we are
>> only looking to check the user is in ldap.
>
> I use this:
>
> LDAP_USER_EXISTS = ${lookup ldap
> {ldap:///ou=People,dc=lobefin,dc=net??sub?(&(accountStatus=active)(uid=${quote_ldap:$local_part}))}
> {$value}{}}
>
> Followed by:
>
> ldap_lookup:
> debug_print = "R: ldap_lookup for $local_part@$domain"
> driver = redirect
> address_data = LDAP_USER_EXISTS
> data =
>
> Followed by some other routers that deal with the data.


And these can deliver to maildir, using the uid/gid captured below?

This is going into Dovecot, so we might just have dovecot owned folders
and deal with it that way.

Thanks.

>
>> How do we set the $uid and $gid for local_delivery via LDAP?
>
> I use:
> user = ${extract{uidNumber}{$address_data}}
> group = ${extract{gidNumber}{$address_data}}


Looks good, thanks.

>
> HTH,
> --
>  --------------------------------------------------------------------------
> |  Stephen Gran                  | I am firm.  You are obstinate.  He is a
> |
> |  steve@???             | pig-headed fool.   -- Katharine
> |
> |  http://www.lobefin.net/~steve | Whitehorn
> |
>  --------------------------------------------------------------------------

>
> --
> ## List details at http://www.exim.org/mailman/listinfo/exim-users
> ## Exim details at http://www.exim.org/
> ## Please use the Wiki with this list - http://www.exim.org/eximwiki/
>