Ldap Routing
am 09.01.2008 18:16:23 von domaotc
I'm confused by these entries in the documention for ldap_routing in
sendmail:
The default map definition is:
ldap -1 -T -v mailHost -k
(&(objectClass=inetLocalMailRecipient)
(mailLocalAddress=%0))
The default map definition is:
ldap -1 -T -v mailRoutingAddress
-k (&(objectClass=inetLocalMailRecipient)
(mailLocalAddress=%0))
Here is my entry, which works replacing "inetLocalAddress" with
"mail", but I don't understand why.
FEATURE(`ldap_routing',`ldap -1 -v mailHost -k
(&(objectClass=inetOrgPerson)(mail=%0))')
I was trying to replace the attribute inetLocalMailRecipient/
mailRoutingAddress with inetOrgPerson/mail and then eventually I
wanted to replace inetLocalMailRecipient/mailHost with exScalixClass/
exScalixMailnode, so in my muddled way of thinking I figured I would
need to do something like:
ldap -1 -T -v mailHost -k (&(objectClass=exScalixClass)
(exScalixMailnode=%0))
and:
ldap -1 -T -v mailRoutingAddress -k
(&(objectClass=inetOrgPerson)
(mail=%0))
Is there some simple explanation for this? I can't find anything on
any posts.
Re: Ldap Routing
am 10.01.2008 08:52:09 von mega
Hi
domaotc@gmail.com wrote:
> I'm confused by these entries in the documention for ldap_routing in
> sendmail:
>
....
>
> ldap -1 -T -v mailHost -k (&(objectClass=exScalixClass)
> (exScalixMailnode=%0))
>
> and:
>
> ldap -1 -T -v mailRoutingAddress -k
> (&(objectClass=inetOrgPerson)
> (mail=%0))
>
> Is there some simple explanation for this? I can't find anything on
> any posts.
I found it helps a lot if you anderstand what exactly you want to
achieve. Before I implemented ldap routing I used ldpsearch to get
mailhost and mailRoutingAddress from the ldap database.
Typically both maps are using the same key (as this is the only key you
have, e.g. the recipient address). So your statements above don't make
that much sense.
In my case I requested the information from a Windoze AD server. I did
not get a mailhost address so a null map was used. For the mail routing
address the value to be used in my AD was 'mail' and the key to the
database was
(&(|(objectclass=user)(objectclass=group))(proxyAddresses=sm tp:%0))
So this here is the FEATURE I use. Remember, I am only interested in the
'mail' attribute. The search key in my case is proxyAddresses.
FEATURE(`ldap_routing', `null', `ldap -1 -T -v mail -k
(&(|(objectclass=user)(objectclass=group))(proxyAddresses=sm tp:%0))',
`bounce')
Of course you will need to specify a reasonable confLDAP_DEFAULT_SPEC.
I can only suggest to use something like ldapsearch to find the correct
syntax and values before writing the map definitions.
HTH
Erich
Re: Ldap Routing
am 10.01.2008 20:16:44 von domaotc
On Jan 10, 2:52 am, Erich Titl wrote:
> Hi
>
> doma...@gmail.com wrote:
> > I'm confused by these entries in the documention for ldap_routing in
> > sendmail:
>
> ...
>
>
>
> > ldap -1 -T -v mailHost -k (&(objectClass=exScalixClass)
> > (exScalixMailnode=%0))
>
> > and:
>
> > ldap -1 -T -v mailRoutingAddress -k
> > (&(objectClass=inetOrgPerson)
> > (mail=%0))
>
> > Is there some simple explanation for this? I can't find anything on
> > any posts.
>
> I found it helps a lot if you anderstand what exactly you want to
> achieve. Before I implemented ldap routing I used ldpsearch to get
> mailhost and mailRoutingAddress from the ldap database.
>
> Typically both maps are using the same key (as this is the only key you
> have, e.g. the recipient address). So your statements above don't make
> that much sense.
>
> In my case I requested the information from a Windoze AD server. I did
> not get a mailhost address so a null map was used. For the mail routing
> address the value to be used in my AD was 'mail' and the key to the
> database was
>
> (&(|(objectclass=user)(objectclass=group))(proxyAddresses=sm tp:%0))
>
> So this here is the FEATURE I use. Remember, I am only interested in the
> 'mail' attribute. The search key in my case is proxyAddresses.
>
> FEATURE(`ldap_routing', `null', `ldap -1 -T -v mail -k
> (&(|(objectclass=user)(objectclass=group))(proxyAddresses=sm tp:%0))',
> `bounce')
>
> Of course you will need to specify a reasonable confLDAP_DEFAULT_SPEC.
>
> I can only suggest to use something like ldapsearch to find the correct
> syntax and values before writing the map definitions.
>
> HTH
>
> Erich
Thanks Erich, I think it is a little clearer.
In your case, you are searching AD for the attribute "mail" based on
the supplied "proxyAddress" attribute. I'm assuming AD doesn't have a
"mailHost" attribute so you have "null":
FEATURE(`ldap_routing', `null', `ldap -1 -T -v mail -k
(&(|(objectclass=user)(objectclass=group))(proxyAddresses=sm tp:
%0))',`bounce')
In my case, I am searching openLDAP for the attribute "mailHost" based
on the supplied "mail" attribute:
FEATURE(`ldap_routing',`ldap -1 -v mailHost -k
(&(objectClass=inetOrgPerson)(mail=%0))')
If these statements are correct, then I guess my question should have
been how do I use the existing attribute "exScalixMailnode" instead of
"mailHost"? To further complicate things, exScalixMailnode is in the
format "mt" and "mt2" and is not a hostname, but it does map to a
hostname: mt=mail.example.com and mt2=mail2.example.com. The
documention makes it clear that mailHost needs to be a FQDN, so
putting an alias in DNS wouldn't solve the problem
Re: Ldap Routing
am 10.01.2008 20:47:38 von Andrzej Filip
domaotc@gmail.com writes:
> On Jan 10, 2:52 am, Erich Titl wrote:
>>[...]
> Thanks Erich, I think it is a little clearer.
> In your case, you are searching AD for the attribute "mail" based on
> the supplied "proxyAddress" attribute. I'm assuming AD doesn't have a
> "mailHost" attribute so you have "null":
>
> FEATURE(`ldap_routing', `null', `ldap -1 -T -v mail -k
> (&(|(objectclass=user)(objectclass=group))(proxyAddresses=sm tp:
> %0))',`bounce')
>
> In my case, I am searching openLDAP for the attribute "mailHost" based
> on the supplied "mail" attribute:
> FEATURE(`ldap_routing',`ldap -1 -v mailHost -k
> (&(objectClass=inetOrgPerson)(mail=%0))')
>
> If these statements are correct, then I guess my question should have
> been how do I use the existing attribute "exScalixMailnode" instead of
> "mailHost"? To further complicate things, exScalixMailnode is in the
> format "mt" and "mt2" and is not a hostname, but it does map to a
> hostname: mt=mail.example.com and mt2=mail2.example.com. The
> documention makes it clear that mailHost needs to be a FQDN, so
> putting an alias in DNS wouldn't solve the problem
Could you post sample LDAP entry in ldif format?
--
[pl>en: Andrew] Andrzej Adam Filip : anfi@priv.onet.pl : anfi@xl.wp.pl
Open-Sendmail: http://open-sendmail.sourceforge.net/
Beauty is one of the rare things which does not lead to doubt of God.
-- Jean Anouilh
----
http://groups.google.com/groups?selm=873at5wjhh@joyce.fsf.ho bby-site.com
Re: Ldap Routing
am 14.01.2008 09:06:58 von mega
domaotc@gmail.com wrote:
> On Jan 10, 2:52 am, Erich Titl wrote:
....
>
> Thanks Erich, I think it is a little clearer.
> In your case, you are searching AD for the attribute "mail" based on
> the supplied "proxyAddress" attribute. I'm assuming AD doesn't have a
> "mailHost" attribute so you have "null":
Correct
>
> FEATURE(`ldap_routing', `null', `ldap -1 -T -v mail -k
> (&(|(objectclass=user)(objectclass=g.... roup))(proxyAddresses=smtp:
> %0))',`bounce')
>
> In my case, I am searching openLDAP for the attribute "mailHost" based
> on the supplied "mail" attribute:
> FEATURE(`ldap_routing',`ldap -1 -v mailHost -k
> (&(objectClass=inetOrgPerson)(mail=%0))')
Looks reasonable.
>
> If these statements are correct, then I guess my question should have
> been how do I use the existing attribute "exScalixMailnode" instead of
> "mailHost"? To further complicate things, exScalixMailnode is in the
> format "mt" and "mt2" and is not a hostname, but it does map to a
> hostname: mt=mail.example.com and mt2=mail2.example.com. The
> documention makes it clear that mailHost needs to be a FQDN, so
> putting an alias in DNS wouldn't solve the problem.
What do you get back with your query? This may help to fully understand
your setting.
Erich