Extmail邮件过滤和杀毒
前面整合好了extmail,不过没有测试使用foxmail这种客户端去测试收发邮件功能,今天测试的时候发现了蛮多问题,大部分和/etc/authmysqlrc这个文件的配置和权限相关,都是小问题,折腾了大半天时间,哎!邮件系统真的是很麻烦!下面就记录下邮件过滤和病毒查杀的配置,参考文档如下,感谢作者分享!
http://www.linuxquestions.in/index.php?topic=36.0
http://linuxguest.blog.51cto.com/195664/199632
一:邮件过滤
- [root@orcl ~]# cd /usr/local/src/tarbag/
- [root@orcl tarbag]# wget ftp://ftp.espci.fr/pub/milter-greylist/milter-greylist-2.0.2.tgz
- [root@orcl tarbag]# tar -zxvf milter-greylist-2.0.2.tgz -C ../software/
- [root@orcl milter-greylist-2.0.2]# ./configure --prefix=/usr/local/greylist
- Required libmilter not found. Use --with-libmilter
- [root@orcl milter-greylist-2.0.2]# yum -y install sendmail-devel
- [root@orcl milter-greylist-2.0.2]# make && make install
- [root@orcl milter-greylist-2.0.2]# ls /usr/local/greylist/
- bin man
- [root@orcl milter-greylist-2.0.2]# cp rc-redhat.sh /etc/init.d/greylist
- [root@orcl milter-greylist-2.0.2]# chmod +x /etc/init.d/greylist
- [root@orcl milter-greylist-2.0.2]# chkconfig --add greylist
- [root@orcl milter-greylist-2.0.2]# chkconfig greylist on
- [root@orcl ~]# tail -1 /etc/postfix/main.cf
- smtpd_milters = unix:/var/milter-greylist/milter-greylist.sock
- [root@orcl ~]# grep -v '^#' /etc/mail/greylist.conf |grep -v '^$'
- acl whitelist addr 127.0.0.0/8
- greylist 2m
- acl whitelist addr 12.5.136.141/32 # Southwest Airlines (unique sender)
- acl whitelist addr 12.5.136.142/32 # Southwest Airlines
- acl whitelist addr 12.5.136.143/32 # Southwest Airlines
- acl whitelist addr 12.5.136.144/32 # Southwest Airlines
- acl whitelist addr 12.107.209.244/32 # kernel.org (unique sender)
- ……………………输出省略…………………………
- [root@orcl ~]# service greylist start
- Starting Milter-Greylist: [ OK ]
- [root@orcl ~]# ls /var/milter-greylist/milter-greylist.*
- /var/milter-greylist/milter-greylist.pid /var/milter-greylist/milter-greylist.sock
- [root@orcl ~]# /usr/local/postfix/sbin/postfix stop
- postfix/postfix-script: stopping the Postfix mail system
- [root@orcl ~]# /usr/local/postfix/sbin/postfix start
- postfix/postfix-script: starting the Postfix mail system
- [root@orcl ~]# tail -f /var/log/maillog
- Sep 13 15:58:10 orcl milter-greylist: User admin@yang.com authenticated, bypassing greylistingSep 13 15:58:10 orcl postfix/smtpd[17243]: 6A20723EFB9: client=unknown[192.168.227.1], sasl_method=LOGIN, sasl_username=admin@yang.com
- Sep 13 15:58:10 orcl postfix/cleanup[17265]: 6A20723EFB9: message-id=<2011091315575673407321@yang.com>Sep 13
- 15:58:10 orcl milter-greylist: smfi_getsymval failed for {if_addr}
- Sep 13 15:58:10 orcl postfix/qmgr[13086]: 6A20723EFB9: from=<admin@yang.com>, size=1749, nrcpt=1 (queue active)Sep 13 15:58:10 orcl postfix/smtpd[17243]: disconnect from unknown[192.168.227.1]
- Sep 13 16:04:35 orcl postfix/smtp[17488]: 6A20723EFB9: to=<ylw6006@163.com>, relay=163mx03.mxmail.netease.com
- [123.125.50.140]:25, delay=385, delays=348/0.01/32/5.1, dsn=2.0.0, status=sent (250 Mail OK queued as
- 25,S8CowEC5tkmLDm9O7JYgAA--.7130S2 1315901072)
- Sep 13 16:04:35 orcl postfix/qmgr[13086]: 6A20723EFB9: removed
二:邮件杀毒
- [root@orcl ~]# cd /usr/local/src/tarbag/
- [root@orcl tarbag]# wget http://nchc.dl.sourceforge.net/project/clamav/clamav/0.97.2/clamav-0.97.2.tar.gz
- [root@orcl tarbag]# tar -zxvf clamav-0.97.2.tar.gz -C ../software/
- [root@orcl tarbag]# cd ../software/clamav-0.97.2/
- [root@orcl clamav-0.97.2]# groupadd clamav
- [root@orcl clamav-0.97.2]# useradd -g clamav clamav
- [root@orcl clamav-0.97.2]# ./configure --prefix=/usr/local/clamav
- [root@orcl clamav-0.97.2]# make && make install
- [root@orcl clamav-0.97.2]# ls /usr/local/clamav/
- bin etc include lib sbin share
- [root@orcl clamav-0.97.2]# mkdir /usr/local/clamav/logs
- [root@orcl clamav-0.97.2]# mkdir /usr/local/clamav/update
- [root@orcl ~]# grep -v '^#' /usr/local/clamav/etc/clamd.conf |grep -v '^$'
- LogFile /usr/local/clamav/logs/clamd.log
- PidFile /usr/local/clamav/update/clamd.pid
- DatabaseDirectory /usr/local/clamav/update
- LocalSocket /tmp/clamd.socket
- [root@orcl ~]# grep -v '^#' /usr/local/clamav/etc/freshclam.conf |grep -v '^$'
- DatabaseDirectory /usr/local/clamav/update
- UpdateLogFile /usr/local/clamav/logs/freshclam.log
- PidFile /usr/local/clamav/update/freshclam.pid
- DatabaseMirror database.clamav.net
- [root@orcl ~]# touch /usr/local/clamav/logs/freshclam.log
- [root@orcl ~]# touch /usr/local/clamav/logs/clamd.log
- [root@orcl ~]# chown -R clamav.clamav /usr/local/clamav/
- [root@orcl ~]# /usr/local/clamav/bin/freshclam
- ClamAV update process started at Tue Sep 13 16:34:37 2011
- Downloading main.cvd [100%]
- main.cvd updated (version: 53, sigs: 846214, f-level: 53, builder: sven)
- WARNING: Your ClamAV installation is OUTDATED!
- WARNING: Current functionality level = 43, recommended = 53
- DON'T PANIC! Read http://www.clamav.net/support/faq
- Downloading daily.cvd [ 67%]
- [root@orcl ~]# /usr/local/clamav/bin/clamscan -r /email --remove -l /usr/local/clamav/logs/clamscan.log
- /email/mailbox/yang.com/admin/Maildir/maildirsize: OK
- /email/mailbox/yang.com/admin/Maildir/.Junk/extmail-curcache.db: OK
- /email/mailbox/yang.com/admin/Maildir/.Junk/maildirfolder: Empty file
- /email/mailbox/yang.com/admin/Maildir/.Junk/extmail-curcnt: OK
- /email/mailbox/yang.com/admin/Maildir/extmail-curcache.db: OK
- /email/mailbox/yang.com/admin/Maildir/.Drafts/extmail-curcache.db: OK
- /email/mailbox/yang.com/admin/Maildir/.Drafts/maildirfolder: Empty file
- /email/mailbox/yang.com/admin/Maildir/.Drafts/extmail-curcnt: OK
- /email/mailbox/yang.com/admin/Maildir/abook.cf: OK
- /email/mailbox/yang.com/admin/Maildir/extmail-curcnt: OK
- /email/mailbox/yang.com/admin/Maildir/.Sent/cur/1315209989.M694119P12554V000000000000FD00I0033598A,S=352:2,S: OK
- /email/mailbox/yang.com/admin/Maildir/.Sent/cur/1315470328.M899053P31309V000000000000FD00I00335AD8,S=348:2,S: OK
- /email/mailbox/yang.com/admin/Maildir/.Sent/cur/1315293753.M922202P5384V000000000000FD00I0033598C,S=306:2,S: OK
- /email/mailbox/yang.com/admin/Maildir/.Sent/cur/1315293677.M625955P5320V000000000000FD00I0033598B,S=311:2,S: OK
- /email/mailbox/yang.com/admin/Maildir/.Sent/cur/1315554157.M6165P4649V000000000000FD00I00335ADA,S=186136:2,ASA: OK
- /email/mailbox/yang.com/admin/Maildir/.Sent/cur/1315360552.M565430P23846V000000000000FD00I00335ACD,S=340:2,S: OK
- /email/mailbox/yang.com/admin/Maildir/.Sent/cur/1315470293.M558036P16741V000000000000FD00I00335AD7,S=344:2,S: OK
- /email/mailbox/yang.com/admin/Maildir/.Sent/extmail-curcache.db: OK
- /email/mailbox/yang.com/admin/Maildir/.Sent/maildirfolder: Empty file
- /email/mailbox/yang.com/admin/Maildir/.Sent/extmail-curcnt: OK
- /email/mailbox/yang.com/admin/Maildir/.Trash/cur/1315209216.M252889P11932V000000000000FD00I00335983,S=95506:2,SA:
- OK
- /email/mailbox/yang.com/admin/Maildir/.Trash/cur/1315209389.M952518P12149V000000000000FD00I00335985,S=95465:2,SA:
- OK
- /email/mailbox/yang.com/admin/Maildir/.Trash/cur/1315209575.M622698P12333V000000000000FD00I00335985,S=95473:2,ASA:
- OK
- /email/mailbox/yang.com/admin/Maildir/.Trash/extmail-curcache.db: OK
- /email/mailbox/yang.com/admin/Maildir/.Trash/maildirfolder: Empty file
- /email/mailbox/yang.com/admin/Maildir/.Trash/extmail-curcnt: OK
- /email/mailbox/yang.com/admin/Maildir/fileman/filesize: OK
- ----------- SCAN SUMMARY -----------
- Known viruses: 1034901
- Engine version: 0.97.2
- Scanned directories: 30
- Scanned files: 23
- Infected files: 0
- Data scanned: 0.81 MB
- Data read: 0.48 MB (ratio 1.68:1)
- Time: 42.771 sec (0 m 42 s)
本文转自斩月博客51CTO博客,原文链接http://blog.51cto.com/ylw6006/663459如需转载请自行联系原作者
ylw6006
Extmail邮件过滤和杀毒的更多相关文章
- 手工杀毒辅助软件(PC Hunter) V1.51 免费绿色版
软件名称: 手工杀毒辅助软件(PC Hunter) 软件语言: 简体中文 授权方式: 免费软件 运行环境: Win 32位/64位 软件大小: 4.7MB 图片预览: 软件简介: PC Hunter是 ...
- XueTr 0.45 (手工杀毒辅助工具) 绿色版
软件名称: XueTr 0.45 (手工杀毒辅助工具)软件语言: 简体中文授权方式: 免费软件运行环境: Win7 / Vista / Win2003 / WinXP 软件大小: 3.3MB图片预览: ...
- linux下杀毒工具clamav
ClamAV 杀毒是Linux平台最受欢迎的杀毒软件,ClamAV属于免费开源产品,支持多种平台,如:Linux/Unix.MAC OS X.Windows.OpenVMS.ClamAV是基于病毒扫描 ...
- 在centos7上安装ClamAV杀毒,并杀毒(centos随机英文10字母)成功
前言 上传文件的时候发现总是失败,查看top发现有个进程一直cpu占用80%以上,而且名称还是随机数.kill之后,一会儿又重新生成了.突然发现居然没有在服务端杀毒的经历.在此处补齐. 安装clama ...
- Atitit 通过调用gui接口杀掉360杀毒 360卫士 qq保镖等难以结束的进程(javac# php )
Atitit 通过调用gui接口杀掉360杀毒 360卫士 qq保镖等难以结束的进程(javac# php ) 1.1. 这些流氓软件使用操作系统os提供的普通api根本就杀不掉啊1 1.2. 使用 ...
- WEKA使用(基础配置+垃圾邮件过滤+聚类分析+关联挖掘)
声明: 1)本文由我bitpeach原创撰写,转载时请注明出处,侵权必究. 2)本小实验工作环境为Windows系统下的WEKA,实验内容主要有三部分,第一是分类挖掘(垃圾邮件过滤),第二是聚类分析, ...
- PowerTool(杀毒辅助工具) V4.6 中文免费绿色版
软件名称: PowerTool(杀毒辅助工具)软件语言: 简体中文授权方式: 免费软件运行环境: Win7 / Vista / Win2003 / WinXP 软件大小: 968KB图片预览: 软件简 ...
- Linux.杀毒.Centos安装杀毒软件Clam
Linux系统用了几年, 甚少中毒 但前不久在阿里云的服务器被种马,折腾了几周才解决干净 感觉还是装个杀毒/马软件定期扫一扫比较稳妥, 这个Clam是免费的, 安装和配置办法记录如下: 已验证适用环境 ...
- 有了这8款Mac安全杀毒和流氓防护软件,让你的mac清理优化,更加安全
其实Mac系统相对Windows来说更加安全,主要原因是针对Mac系统的病毒和流氓软件并不多,而且Mac系统的安全机制也更加完善,不过为了更加安全的使用Mac,使用以下8款Mac 杀毒安全.安全防护和 ...
随机推荐
- Hadoop (六):MapReduce基本使用
MapReduce原理 背景 因为如果要对海量数据进行计算,计算机的内存可能会不够. 因此可以把海量数据切割成小块多次计算. 而分布式系统可以把小块分给多态机器并行计算. MapReduce概述 Ma ...
- Windows恢复分区管控命令reagentc
reagentc命令可以实现Windows恢复分区的开关,创建.删除,状态查看. 可以只管确定当前系统恢复分区所在位置,便于删除多余的恢复分区.
- Visual Studio2000系列版本安装OpenGL可以这么简单!
是啥 直接上图 [翻译过来]这个库将各种库添加到您的项目中,这些库在x86和x64架构上构建OpenGL应用程序所必需的.包括FreeGLUT,GLFW和GLEW.也就是说,大家常用的几个OpenGL ...
- 详解java访问修饰符
详解java访问修饰符 为了防止初学者看到因为专业的术语而感觉晦涩难懂,我接下来尽量用生动比喻的说法来解释!首先第一点,我们来讲讲什么叫修饰符!看看这个名称,想想他的意思.修饰符!修饰符!,就是用来修 ...
- STC15W串口通信的一些梳理
由于控制串口1进行通信移植到串口3出现了阻力,因此很有必要对串口通信进行更进一步的梳理>>>> 一 STC15W串口对应引脚: 由此我们得到四个串口引脚分别为:串口1:P3 . ...
- go 中的WaitGroup
wait_group sync.WaitGroup 类型是并发安全的,也是开箱就能用的. 该类型有三个指针方法,即:Add,Done和Wait. sync.WaitGroup是一个结构体类型.其中一个 ...
- Weblogic-SSRF 漏洞复现
0x01 环境搭建 我这里使用的是vulhub,它几乎包含了所有的漏洞环境.(建议安装在ubuntu上) 有需要的小伙伴来企鹅群自取. 安装好vulhub之后需要cd 到weblogic ssrf 目 ...
- [PHP] 获取IP 和JS获取IP和地址
通过js获取 服务器 ip 服务器端口 服务器地址 var address=window.location.href; thisDLoc = document.location; var hostpo ...
- 使用mysqlbinlog查看二进制日志
(一)mysqlbinlog工具介绍 binlog类型是二进制的,也就意味着我们没法直接打开看,MySQL提供了mysqlbinlog来查看二进制日志,该工具类似于Oracle的logminer.my ...
- 替换字符串sql
update [表名] set 字段名 = replace(与前面一样的字段名,'原本内容','想要替换成什么') UPDATE `zjl_III_hei_zlj_20151111`.`ctrl_ne ...