2.vi /etc/postfix/main.cf 增加
- 代碼: 選擇全部
content_filter = amavis:[127.0.0.1]:10025
3.vi /etc/postfix/master.cf 增加
- 代碼: 選擇全部
amavis unix - n n - 10 pipe user=amavis argv=/usr/sbin/amavis ${sender} ${recipient}
localhost:10025 inet n - n - - smtpd -o content_filter=
4.vi /etc/amavisd.conf 增加
- 代碼: 選擇全部
$sophos = "/usr/local/bin/sweep";
$sophos_ide_path = "/usr/local/sav";
# yes - syslog, no - file logging
$DO_SYSLOG = "yes";
# Directory to put log entries (if not using syslog)
$LOGDIR = "/var/log/amavis";
$LOGFILE = "amavis.log";
# 0: default - startup/exit/failure messages
# 1: args passed from client
# 2: virus scanner output
# 3: server client
# 4: decompose parts
$log_level = 0;
5.到 Sophos AntiVirus
http://www.sophos.com抓試用版 for Linux 的掃毒程 式, 如果你是使用2.4 Kernel 的抓 linux.intel.libc6.tar,使用2.2 Kernel 的抓 linux.intel.libc5.tar.
- 代碼: 選擇全部
# tar xvf linux.intel.libc6.tar
# groupadd sweep
# useradd -g sweep -s /bin/false -c "Sophos AntiVirus" sweep
# cd sav-install
# ./install.sh -v
6.重新啟動 Postfix 與 Amavisd
- 代碼: 選擇全部
/etc/init.d/postfix reload
/etc/init.d/amavis-postfix restart
附記:使用Sophos的病毒碼,需要付費.