How to whitelist domain in spamassassin

Post Reply
User avatar
isscbta
Team Member
Posts: 130
Joined: Mon Jul 19, 2021 1:41 am
Has thanked: 15 times
Been thanked: 3 times

In your SSH, as root, run:

Code: Select all

mcedit /etc/spamassassin/local.cf
At the end of file, bellow dns_server 127.0.0.1 add email which you want to whitelist in this format:
whitelist_from *@domain.com

Example:

Code: Select all

# This is the right place to customize your installation of SpamAssassin.
#
# See 'perldoc Mail::SpamAssassin::Conf' for details of what can be
# tweaked.
#
# Only a small subset of options are listed below
#
###########################################################################

#   Add *****SPAM***** to the Subject header of spam e-mails
#
# rewrite_header Subject *****SPAM*****


#   Save spam messages as a message/rfc822 MIME attachment instead of
#   modifying the original message (0: off, 2: use text/plain instead)
#
# report_safe 1

dns_server 127.0.0.1

whitelist_from *@domain.com
At the end you have to restart spamassassin.
On Debian version < 12, run:

Code: Select all

systemctl restart spamassassin
On Debian version >= 12, run:

Code: Select all

systemctl restart spamd

Tags:
Post Reply