Zimbra offers Open Source email server software and shared calendar for Linux and the Mac
Go Back   Zimbra :: Forums > Zimbra Collaboration Suite > Administrators

Welcome to the Zimbra :: Forums!
Welcome, if you would like to post a comment please register. We also encourage you to explore all things Zimbra with our team and members of the community.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 04-23-2009, 09:20 AM
Junior Member
 
Posts: 7
Default setting domain-wide mail filter

Is it possible to setup a domain-wide mail filter? I know users have the ability to do this in the Preferences|Mail Filters section, but it obviously only applies to messages sent to that specific user. The domain administrator doesn't seem to have any way to do this when logged into the admin interface.
If there isn't a way to do this through the web interface can it be done via CLI?
Thanks.
Reply With Quote
  #2 (permalink)  
Old 04-23-2009, 01:24 PM
Zimbra Employee
 
Posts: 604
Default

Not quite sure I understand the use case, can you elaborate on the intended use?
__________________
Bugzilla - Wiki - Downloads - Before posting... Search!
Reply With Quote
  #3 (permalink)  
Old 04-23-2009, 02:06 PM
Junior Member
 
Posts: 7
Default

I'm talking about the Mail Filter within the Preferences section in the web interface. Users can create filters that will perform an action (bounce, forward, move to folder, etc.) on messages based on various conditions (subject, To/From address, etc.). Is there a way to apply one of these filters across all users within a domain?
As an example, domain.com is hosted on our Zimbra system. The domain admin want all their accounts to automatically forward any message from user@externaldomain.com to another email address.
Reply With Quote
  #4 (permalink)  
Old 05-18-2009, 01:21 PM
Junior Member
 
Posts: 7
Default

Is there any update on my question? Our domain administrators found this feature very useful in Imail and SmarterMail. It could be used to block all emails from a specific email address or domain; or to move messages with "SPAM" in the subject line to a junk mail folder. It is intended to apply these rules across the entire domain.
If there is no such funtionality, what is the best way to take a user's filter and apply it to all users in that domain?
What is the proper way to request such a feature?
Thanks.
Reply With Quote
  #5 (permalink)  
Old 07-21-2009, 03:37 AM
Senior Member
 
Posts: 70
Default

Are there anyupdates on this query whioch will be very useful?
Reply With Quote
  #6 (permalink)  
Old 07-21-2009, 04:20 AM
Zimbra Consultant & Moderator
 
Posts: 20,313
Default

Quote:
Originally Posted by tiarra View Post
Are there anyupdates on this query whioch will be very useful?
Not unless anyone has filed a bug report or RFE in bugzilla.
__________________
Regards


Bill

Last edited by phoenix; 10-10-2009 at 08:17 AM..
Reply With Quote
  #7 (permalink)  
Old 10-10-2009, 07:38 AM
Junior Member
 
Posts: 6
Default Opened Request for enhancement.

Although there were a lot of bugs under search for 'domain filter' none appeared to fit our criteria
New bug - 41688
Reply With Quote
  #8 (permalink)  
Old 10-10-2009, 09:41 PM
Elite Member
 
Posts: 338
Default

postfix had a solution about this problem, you can read in it's webpage. But I'm not sure when apply in zimbra ( Hope this can works because zimbra uses postfix as it's MTA)
Reply With Quote
  #9 (permalink)  
Old 10-11-2009, 04:38 AM
Junior Member
 
Posts: 6
Default Create rules for every email address of a domain using shell

With the help of
http://www.goldfisch.at/knowwiki/bas...?do=export_raw (giving good examples)
How to check mailbox size of all accounts in Zimbra mail server. | STORY of AODDY. (good example of going through all accounts and doing a routine)
CLI of zimbra -h
I've come up with a set of instuctions and script which should complete the required task of making a NEW domain wide filter through seive. There probrably is an easier way to do it because it's creates a new rule for every email address. I see zimbra has maildrop but I'm to scared to tamper with main.cf and whatever .cf files. This set of instructions needs to be expanded to be put into a cron job in case of new email addresses and to not duplicate already made filters on email accounts.
So please nitpick, correct, enhance, or best of all give a better solution with detailed instructions.
**************************
cd /opt/zimbra/bin
vi filter1.sh

#!/bin/bash
all_account=`zmprov gaa |grep @whaterverdomain.com`
for account in ${all_account}
do
`zmmailbox -m ${account} -z afrl "nameoffilter1" active any header "subject" contains "***SPAM***" fileinto "Inbox/spam" stop`

done

:wq

su zimbra
./filter1.sh
*************

Use at your own risk
Reply With Quote
  #10 (permalink)  
Old 10-11-2009, 06:35 AM
Moderator
 
Posts: 7,928
Default

You should use
Code:
su - zimbra
so that it sources in the profile and paths.
__________________
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads

Why Join?

Registering let's you ask questions, makes it easier to search, displays any files attached to posts, and notifies you about replies.

blog.zimbra.com




 

SEO by vBSEO ©2011, Crawlability, Inc.