1

Topic: How to change Virus behaviour

==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release): V1.2.1
- downloadable installer
- Linux/BSD distribution name and version:
Ubuntu 18.04
- Store mail accounts in which backend MySQL
- Web server: Nginx
====

Hello,

I want to change the behaviour from amavisd.
I want that all Mails that got checked positive for Viruses, Spam or blocked file extensions or bad Headers or whatever else get's checked get marked in the Subject line and moved to the Spam folder. Right now that only happens to Spam Mails.
I've changed the final destination parameters in the amavisd config to d_pass.
Now i can recive all blocked mails and mails with viruses too and only spam mails get marked and moved into the spam folder. How can I change that also other mails get marked and moved to spam?

Best regards,
Maurice Klein

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: How to change Virus behaviour

You need to check mail headers of these emails, find the one which indicates it's a virus/bad-header/whatever, then create a sieve rule to match the header and move to spam folder.

3

Re: How to change Virus behaviour

ZhangHuangbin wrote:

You need to check mail headers of these emails, find the one which indicates it's a virus/bad-header/whatever, then create a sieve rule to match the header and move to spam folder.

Thanks for your reply.
The problem is, that the mails don't go into my mails at all cause they get into the sql quarantine. How can I change it that they get into my inbox.
The filtering via sieve I can do then.

4

Re: How to change Virus behaviour

Run SQL command as SQL root user below:

USE amavisd;
UPDATE policy SET virus_lover='Y',bad_header_lover='Y',virus_quarantine_to=NULL,bad_header_quarantine_to=NULL WHERE policy_name='@.';