How to block all emails with specific link/domain in the body of the email

poetry

Active Member
May 28, 2020
206
57
33
For example I would like to block all emails that contain links to for example onedrive.live.com (https://onedrive.live.com/ and http://onedrive.live.com/). This means that any emails that contain this domain/link/text would be blocked.

What would be the easiest way to do this in proxmox. Someone suggested to do this in clamav but it does not work for me.
Thanks.

For exemple, to drop onedrive links :
echo "OneDriveLink:0:*:3c75726c737472696e673e68747470733a2f2f6f6e6564726976652e6c6976652e636f6d2f646f776e6c6f6164" >/var/lib/clamav/onedrivelink.ndb
/etc/init.d/clamav-daemon restart
 
@hata_ph thanks for the help. I struggled a bit to get it working but now it's ok.

1. cp /etc/mail/spamassassin/custom.cf /etc/pmg/templates/custom.cf
2. nano /etc/pmg/templates/custom.cf (copy the contents of hata_ph into this file)
3. pmgconfig sync --restart 1

Then restart the whole server. It did not work if I tried to restart just services I don't know why but whatever. It's working now.
 
  • Like
Reactions: hata_ph

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!