星期五, 4月 15, 2005

Sendmail+MailScanner4.40+Clamav0.83

今天心血來潮
又做了一次Sendmail+MailScanner4.40+Clamav0.83
O/S: Redhat 9.0
Mail server: Sendmail
使用套件: clamav-0.83
clamav-db-0.83
MailScanner-4.40


1.取得MailScanner

http://www.sng.ecs.soton.ac.uk/mailscanner/

點選Download 選取您的版本並儲存

2.解壓縮檔案 小弟抓的是4.40版

#tar zxvf MailScanner-4.40.11-1.rpm.tar.gz

3.安裝MailScanner
#cd MailScanner-4.40.11-1/
#./install.sh

完成MailScanner 的安裝

4.取得防毒軟體 Clam AntiVirus
由rpmfind.org 下載 clamav套件
關鍵字 clamav and clamav-db

下載: http://dag.wieers.com/packages/clamav/

5.安裝clamav套件

#rpm -ivh clamav-db-0.83-1.0.rh9.rf.i386.rpm
#rpm -ivh clamav-0.83-1.0.rh9.rf.i386.rpm
#rpm -ivh clamav-devel-0.83-1.0.rh9.rf.i386.rpm
#rpm -ivh clamav-milter-0.83-1.0.rh9.rf.i386.rpm
#rpm -ivh clamd-0.83-1.0.rh9.rf.i386.rpm

6.修改Mail Scanner 設定讓Mail Scanner 和 Clam Anti Virus結合

#cd /etc/MailScanner
#vi MailScanner.conf

找尋 Virus Scanner = none
改成 Virus Scanner = clamav
修改一下MailScanner的設定檔
%org-name% = yoursite -->個人或公司的簡稱
%org-long-name% = Your Organisation Name Here --> 公司或個人全名
%web-site% = www.your-organisation.com --> 公司或個人網址
Notify Senders = no --> 不通知原寄信人....如果他是廣告商怎辦^^還通知他勒
Virus Subject Text = {病毒信?} --> 收到病毒信加上{病毒信?}的字串原來是英文改中文
Spam Subject Text = {廣告信?} --> 收到廣告信加上{廣告信?}的字串原來是英文改中文
Archive Mail = /var/spool/MailScanner/archive -->備份寄出/入信件於指定目錄...請注意隱私權的問題還有必須手動建立目錄 #mkdir /var/spool/MailScanner/archive

儲存後離開 (:wq)

7.讓MailScanner 接手Sendmail的工作啟動防毒機制

#service sendmail stop
#chkconfig sendmail off
#chkconfig --level 2345 MailScanner on
#service MailScanner start


8.啟動clamd 讓clamav 定時更新
#service clamd start

沒有留言: