Can anybody help me about that?
[]s Jarbas
Remy Zandwijk escreveu:
Hi Jarbas,
Nice solution, but how do you handle ldap searches from different Samba domains? I mean, all searches will use the same filter, which will be converted to another filter. Is OpenLDAP capable of 'rewrite when search from IP number x.x.x.x' ?
Remy
In reference at http://lists.samba.org/archive/samba/2005-August/108999.html and http://threebit.net/mail-archive/samba/msg00118.html
Hi Remy, Hi Norbert,
I have the similar problem e I resolved with the "overlay rwm in openldap".
If in smb.conf I haved: ldap filter = (&(iufmLogin=%u)(gecos=#*))
When the new samba search by any user, the following filter in openldap is used: (&(uid=user)(objectClass=sambaSamAccount)). Then the overlay replace by filter by (&(iufmLogin=$1)(gecos=#*)) only in openldap server.
My slapd.conf (only the part with overlay rwm) is: ... moduleload rwm overlay rwm rwm-rewriteEngine on rwm-rewriteContext searchFilter rwm-rewriteRule "\(&\(uid=([a-z0-9_]+)\)\(objectClass=sambaSamAccount\)\)" "(&(iufmLogin=$1)(objectClass=sambaSamAccount))" ":@I" ...
This work fine to me.