

Basically means any spam can arrive to this local domain list, which is not usually what would be desired.Īn wilcard address list of sending/From emails that should be accepted without any scanning. It should be 0 bytes 99.999% of the time. However this is for the destination domains, meaning NO SCANNING WILL BE DONE on these recipient domains. This is also an nwildsearch, so the same format at the blacklist_domains applies.

These 3 files are meant to block OUTBOUND email from leaving your server. etc/virtual/blacklist_usernames /etc/virtual/blacklist_smtp_usernames /etc/virtual/blacklist_script_usernames # Outbound DirectAdmin Username/SMTP login blocks Make sure "Use RBL Blocking" is enabled, else the blacklist files will not have any effect. Usually, you'd just go to Admin Level -> Admin Settings -> Use RBL Blocking to enable it, which replaces the use_rbl_domains file, with a symlink to the domains file (all domains on the server). NOTE: These 2 files will only be activated on domains which are enabled in the /etc/virtual/use_rbl_domains file. To enable RBL blocking for all current and future domains via the command line as root, run the following:

If you enable it, the file will be deleted and it will be replaced by a link to "domains". So, if you are using the use_rbl_domains as a file and are manually updating it, leave the option disabled. Note: This option will show enabled if /etc/virtual/use_rbl_domains is a a link, and disabled if it's a file. To enable RBL blocking for all current and future domains via the DirectAdmin GUI, use the following:Īdmin Level -> Admin Settings -> Use RBL Blocking Only use this option if you are certain that you want very aggressive RBL blocking.
#SPAMASSASSIN RULE HOW TO#
# How to enable realtime blocklists (RBLs) with Eximīecause SpamAssassin already factors in RBLs in its spam scoring and blocking, you can leave this option disabled and still benefit from RBLs. Which tells all DNS queries that your server makes, to call your local copy of "named", instead of querying the remote DNS server for lookups.Īs RBLs are all DNS based, this means your RBL queries to the RBL servers would now be coming from your server, and not from a big DNS server, like 8.8.8.8, so it's most likely to go through. Sending outbound email through remote mail server.Autodiscover information for mail clients.I'd say DNSBLs and Bayesian content inspection are the two best weapons to combat spam overall. You could also consider doing this automatically via TxRep, but only after making sure you're properly using IP DNSBLs (see DnsBlocklists). You can also use def_whitelist_from_dkim and def_whitelist_from_spf for lighter ham weights. Instead, I'd recommend explicitly blessing known-safe domains: whitelist_from_dkim allows valid DKIM-signed and SPF-authorized mail from just the listed domains. _DKIM_EXISTS is nearly identical to DKIM_SIGNED.Ģ2.5% of spam and 71.4% of ham have DKIM, meaning 87.5% of spam and 38.6% of ham lack it.ĭo you really want to remove 2 points from a ~quarter of your spam and add 1 point to a ~third of your ham? Since these don't run the DKIM plugin on all tests, let's look at _DKIM_EXISTS (there is a DKIM signature header) instead of DKIM_SIGNED (there is a properly-formatted DKIM signature header) or DKIM_VALID (it matches). You can look this up and see: Consider the public SpamAssassin Rule QA logs for. Similarly, lots of legitimate mails fail to use (or correctly implement) either SPF or DKIM. You'd be giving all of them a big ham weight (-2), making it that much harder for SpamAssassin to convict them. Those infrastructures all have proper DKIM and SPF signing. Then there's all of the attacks that come in through freemail providers like GMail, Yahoo, Hotmail/Outlook, etc. Lots of spammers and dirty marketers implement SPF and DKIM.

⚠ However, I recommend neither that nor tinkering with DKIM/SPF weights. It also uses a conditional to ensure the plugin is loaded, as otherwise !DKIM_SIGNED would again always be true.) The solution is to give it a trivial score. (Assigning a zero score to a rule disables its evaluation, so !DKIM_SIGNED would always be true. You can do that like this: ifplugin Mail::SpamAssassin::Plugin::DKIM
