Whitelist and Blacklist domain in zimbra

In this tutorial we will look , how we can blacklist and whitelist email id and domain using file /opt/zimbra/conf/amavisd.conf.in

Note: We need to score the domain and email id rate. Scoring Positive is Blacklist and Negative score is Whitelist .
Positive Score = Blacklist
Negative Score=Whitelist

Whitelist domain using file /opt/zimbra/conf/amavisd.conf.in 
Login with zimbra user
#su - zimbra
$vim /opt/zimbra/conf/amavisd.conf.in

{ # a hash-type lookup table (associative array)
     'example.com'                        => -10.0,
     'nobody@cert.org'                        => -3.0,
     'cert-advisory@us-cert.gov'              => -3.0,
     'owner-alert@iss.net'                    => -3.0,
     'slashdot@slashdot.org'                  => -3.0,

or, For Email id whitelist

{ # a hash-type lookup table (associative array)
     'emailid@example.com'                        => -10.0,
     'nobody@cert.org'                        => -3.0,
     'cert-advisory@us-cert.gov'              => -3.0,
     'owner-alert@iss.net'                    => -3.0,
     'slashdot@slashdot.org'                  => -3.0,

Restart Amavis Service
$zmamavisdctl restart

Blacklist Domain and email id using file /opt/zimbra/conf/amavisd.conf.in 
$vim /opt/zimbra/conf/amavisd.conf.in
{ # a hash-type lookup table (associative array)
     'example.com'                        => 10.0,
     'nobody@cert.org'                        => -3.0,
     'cert-advisory@us-cert.gov'              => -3.0,
     'owner-alert@iss.net'                    => -3.0,
     'slashdot@slashdot.org'                  => -3.0,

or For Email id Blacklist

{ # a hash-type lookup table (associative array)
     'emailid@example.com'                        => 10.0,
     'nobody@cert.org'                        => -3.0,
     'cert-advisory@us-cert.gov'              => -3.0,
     'owner-alert@iss.net'                    => -3.0,
     'slashdot@slashdot.org'                  => -3.0,

Restart Amavis Service
$zmamavisdctl restart

Now send a testing mail from blacklisted email id and check.

Check log file
$tail -f /var/log/zimbra.log
Mar 26 23:32:51 mail postfix/qmgr[20635]: 28C65AC206E2: from=<email@example.com>, size=4214, nrcpt=1 (queue active)
Mar 26 23:32:51 mail amavis[18157]: (18157-01) nnBCMtyI9p7F FWD from <email@example.com> -> <email@xyz.com>, BODY=7BIT 250 2.0.0 from MTA(smtp:[127.0.0.1]:10025): 250 2.0.0 Ok: queued as 28C65AC206E2
Mar 26 23:32:51 mail amavis[18157]: (18157-01) Passed SPAMMY {RelayedTaggedInbound}, [209.85.213.46]:34457 [209.85.213.46] <email@example.com> -> <email@xyz.com>, Queue-ID: 594FAAC206AC, Message-ID: <CAH7ccxTQ104qoy4PFZX2p1RXL=YqDxBG7f+2_hQxzkyeLPZHVQ@mail.gmail.com>, mail_id: nnBCMtyI9p7F, Hits: 7.531, size: 3220, queued_as: 28C65AC206E2, dkim_sd=20120113:gmail.com, 3241 ms

Note: As we now received blacklisted email id in Junk Folder.
Share on Google Plus

About Penguin Technology

I am a passionate cloud and DevOps professional specializing in Linux and open-source solutions. Through this blog, I share my knowledge and experience with the community, offering tips and insights on cloud technologies and DevOps practices.
    Blogger Comment

3 comments:

  1. This comment has been removed by a blog administrator.

    ReplyDelete
  2. Replica Audemars Piguet Watches, combining elegant style and cutting-edge technology, a variety of styles of Replica Audemars Piguet royal-oak-offshore Watches, the pointer walks between your exclusive taste style.

    ReplyDelete
  3. I gathered as much knowledge regarding to the Linux, web sever and database server from your site.Keep on updating with more interesting topic.
    Moreover to recover the lost file from Linux Click on:
    android data recovery review
    launch android data recovery
    backup and restore android apps and data
    android backup app data
    recover lost files
    diskdigger pro file recovery


    ReplyDelete