ClamAV
Apply the following to all Email servers.
Needed application before installation.
Make sure you have bzip2-devel and gmp-devel installed
swup --install bzip2-devel or yum install bzip2-devel
swup --install gmp-devel or yum install gmp-devel
Download and install CURL
http://curl.haxx.se/download.html
Download ClamAV from this web site Clamav
Untar downloaded file
tar -xvzf clamav-0.92.1.tar.gz
Creat a user and group for Clamav
groupadd clamav
useradd clamav -g clamav -C "Clam Antivirus" -s /bin/false
Configure
./configure --disable-zlib-vcheck
make
make install
Updating Definitions files
touch /var/log/clam-update.log
chmod 600 /var/log/clam-update.log
chown clamav /var/log/clam-update.log
Setup a cronjob to update definitions
crontab -e
# Updating for Antivirus
0 4,8,12,16,20,23 * * * /usr/local/bin/freshclam --quiet --log-verbose --daemon-notify
QClam
Download QClam from this web site QClam
Unzip
bunzip2 qclam-0.8.tar.bz2
tar -xvf qclam-0.8.tar.bz2
If your system is not compatible with shipped QClam binary.
make clean
make install
Make sure that clamd is loaded at run time.
Copy or cut and paste this file to your server Clamd init file
Add to /var/qmail/control/defaultdelivery
|/usr/local/bin/qclam --clam /usr/local/bin/clamdscan
|dot-forward .forward
./Mailbox