[Date Prev][Date Next]
[Chronological]
[Thread]
[Top]
Re: basic ldapsearch problem
tor, 2003-02-06 kl. 13:03 skrev Kuba Leszewski:
> Please
> Anyone has any idea ?
I do what you want with Exim 4.12 so-called routers, not with Sendmail.
What you've found is exactly what I've found - however, with Exim one
can use the following for the ldap search paramters.
_________________________
system_aliases:
driver = redirect
allow_fail
allow_defer
data = ${lookup ldapm \
{user="cn=exim,ou=services,ou=groups,dc=billy,dc=demon,dc=nl"
pass=eximspassword \
ldaps://localhost/\
ou=groups,dc=billy,dc=demon,dc=nl?mailRoutingAddress?sub?\
(&(objectClass=inetLocalMailRecipient) \
(mailLocalAddress=${quote_ldap:$local_part@$domain}))\
}\
{$value} fail }
file_transport = address_file
pipe_transport = address_pipe
__________________________
Notice "$local_part@$domain"? They're expansion variables that Exim
fills in from whoever has to do what.
> Maybe somethign is wrong with my indexes ?
> I only have index objectClass eq.
No way. You can try to index mailRoutingAddress, for ex., but it won't
help.
> Maybe I should define more of them ?
Definitely. For other things, though.
> Or maybe it's impossible to search by part of e-mail address ?
Yes, it's impossible. I tried all you suggested for you for the above (I
don't need it, my way works already).
The following works, with a different attribute though:
______________________________
group_aliases_2:
driver = redirect
allow_fail
allow_defer
data = ${lookup ldapm \
{user="cn=exim,ou=services,ou=groups,dc=billy,dc=demon,dc=nl"
pass=eximspassword \
ldaps://localhost/\
dc=billy,dc=demon,dc=nl?rfc822MailMember?sub?\
(&(objectClass=nisMailAlias)(cn=${quote_ldap:$local_part}))\
}\
{$value} fail }
file_transport = address_file
pipe_transport = address_pipe
____________________________________
Notice just: $local_part?
> Maybe I should have records of type inetOrgPerson, to make such search ?
> But Sendmail requires inetLocalMailRecipient type, so I have no choice.
Maybe you should start using Exim 4?
Best,
Tony
--
Tony Earnshaw
When all's said and done ...
there's nothing left to say or do.
e-post: tonni@billy.demon.nl
www: http://www.billy.demon.nl