Ok, I am posting this here because my previous thread is in the old locked Desktop archive.
You can have Evolution scan all of your incoming e-mails for viruses and notify you of any detected.
First you have to install the following packages:
This should install the basic Clamav system that updates itself automatically (there are other clam packages you can install for extra functionality).
Then create a script in a convenient place (like your /home directory), I called mine clam-filter and it contains the following:
After you create it, make it executable:
# Fred Blaise <chapeaurouge AT madpenguin DOT org>
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
# MA 02111-1307 USA
# clamscan for non-daemon scanning - clamdscan when the daemon is installed
clamscan --no-summary --detect-pua=yes --detect-structured=yes - 1>$FILE
if [ $? -eq 1 ]; then
STRING=$(grep "FOUND" $FILE |cut -d: -f2)
zenity --warning --title="Evolution: Malware detected" --text="$STRING" &
logger -t clamav/Evolution <$FILE
Go into Evolution-Edit-Message Filters and create a new Incoming Filter called Virus scan with location of the clam-filter script in the Pipe to Program location and an Evolution folder to dump any e-mails with a virus into (I made one called "Virus Dump) - see attached screenshot.
chmod 777 clam-filter
Make sure that the filter is at the top of the list and all of you incoming e-mails should be checked by Clamav (so you know when you receive a Windows virus or other malware).
You can test the functionality by sending yourself an e-mail containing one of the Eicar test files: