OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
 
Re: virtual_alias_maps: rewriting outbound

From: Magnus Bäck (magnusdsek.lth.se)
Date: Wed Jul 05 2006 - 14:54:20 CDT


On Wednesday, July 05, 2006 at 21:13 CEST,
     Chris McKeever <techjedigmail.com> wrote:

> On 7/3/06, mouss <usebsdfree.fr> wrote:
>
> > why would you do a regex? do it directly in ldap. you're not using
> > any regex "capacity" here. you're just using
> > foodomain => bardomain
> > where bar=function(foo) and domain is one of yours. the only thing
> > is you need to make sure this only returns a result if bardomain
> > exists. I see no regex here. These are just "alternate" mailbox
> > addresses.
>
> ok - that would work, I havent come across any LDAP function references ..
> I will do some digging, if anyone knows a direct link/howto please
> post it...or even a quick
> example
>
> finding a function that would work in LDAP as you described
> bar=function(foo) would be perfect!! good suggestion, now I have to
> find it!

You will find nothing of the sort. LDAP does not have "functions".
The suggestion is that you store the addresses in LDAP.

mail: foo.barexample.com
mailAlternateAddress: f.barexample.com

Or whatever your schema supports.

You may use a function, possibly in your favourite scripting language,
to generate the alternate addresses. Use can then easily use virtual
rewriting to transform mailAlternateAddress -> mail if you need to.

--
Magnus Bäck
magnusdsek.lth.se