Re: LDAP attribute format

Janne Pikkarainen <[email protected]>
Newsgroups gmane.mail.perdition.user
Organization Sanoma Data Oy
Message-ID <[email protected]>
Hello,

Jim Tyrrell wrote:
> Hi,
>
> I have just been looking at using perdition as part of a mail migration 
> between multiple POP3 servers and have it working well with LDAP.
>
> At the moment I have it configured to lookup against the domain part of 
> the user login and have temporarily added the following attribute to the 
> domain object in LDAP:
>
> mailhost=192.168.10.81
>
> That works, but I would like to use an existing attribute that already 
> exists and wouldnt require manually editing the LDAP object everytime a 
> domain was updated.  The problem is this attribute is in the format of:
>
> mailtransport=nexthop:[mda-clusterX.domain.com]
>
> So my query is returning "nexthop:[mdaX.domain.com]".  Is there anyway 
> to get ldap/perdition to retrieve the part of the result thats in the [] 
> brackets?  If I could use that part of the LDAP attribute I would only 
> need to add an entry to the hosts file so that it would use the POP3 
> server that corresponds with the Mail Delivery server in that attribute?
>
> If theres a trick to accimplish that it would save me alot of work. :)
>
>   

I don't think the trick is possible to at Perdition level, but if you 
are using OpenLDAP, you might want to try its rewrite/remap overlay.

That way you don't need to actually modify the data in LDAP database, 
but instead configure an additional view / LDAP URI for Perdition use. 
Rewrite/remap could probably include only the part between the brackets 
by using standard regular expressions. Unfortunately slapo-rwm man page 
reminds me of Apache's mod_rewrite; the good thing about it is that it's 
extremely configurable. The bad part about it is it's extremely 
configurable.

http://www.openldap.org/software/man.cgi?query=slapo-rwm&apropos=0&sektion=0&manpath=OpenLDAP+2.4-Release&format=html

Good luck. I hope this helps.

Best regards,

Janne Pikkarainen
______________________________________________
Perdition-users mailing list
[email protected]
http://lists.vergenet.net/listinfo/perdition-users
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.