Search the web
Sign In
New User? Sign Up
exim-users · Exim MTA
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Real people. Real stories. See how Yahoo! Groups impacts members worldwide.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
[exim] X-Post: LDAP lookup inside system filter   Message List  
Reply | Forward Message #85777 of 85778 |
Hi all

Sorry about the cross-post. I tried this on exim-users with no response so I
thought I would try my luck here.

Really simply: does anyone know if its possible to do LDAP lookups directly in a
system_filter or similar (such as a central_filter using the redirect
transport)? Basically, I want to lookup the OU for a particular mail user and
then perform selective filtering based on what 'organizational unit' that
particular mail user is in, system wide. This can be done either within the
filter script, or declared outside of the script in exim.conf and then 'used' by
the script logic.

For example, I've setup a system-wide central filter as follows:

>central_filter:
> driver = redirect
> domains = +local_domains
> file = /etc/exim/filter1
> no_verify
> user = exim
> group = exim
> allow_filter
> allow_freeze

Then I want to have something like the following inside /etc/exim/filter1

>group = ${lookup ldapm
{ldap://localhost:389/ou=people,dc=testdomain,dc=com?ou?(mail=${local_­part})}{$\
value}
>
>if $group is "marketing" then save /dev/null endif

Does anyone know how to do this or if its possible? I found this post:
http://www.exim.org/mail-archives/exim-users/Week-of-Mon-20030310/msg00292.html
but no further information on the matter.

Perhaps I can lookup the group information outside of the central_filter, then
pass that information to the filtering script?

Also, I understand theres some caveats between system_filters and
central_filters with regards to multiple recipients which is why I chose to use
the redirect/central_filter model. Are there any problems with this approach?

-a



--
## List details at http://www.exim.org/mailman/listinfo/exim-users
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://www.exim.org/eximwiki/



Fri Oct 7, 2005 10:21 pm

ashkan@...
Send Email Send Email

Forward
Message #85777 of 85778 |
Expand Messages Author Sort by Date

Hi all Sorry about the cross-post. I tried this on exim-users with no response so I thought I would try my luck here. Really simply: does anyone know if its...
ashkan
ashkan@...
Send Email
Oct 7, 2005
10:23 pm
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help