当前位置:网站首页>Remedy after postfix becomes a spam transit station
Remedy after postfix becomes a spam transit station
2022-04-23 05:53:00 【Mu Meiwen】
Corporate email servers have recently been used as transit stations to forward a large number of advertising emails , Record the remedial process here .
- First clear the spam sending task in the queue ;
stop it sendmail service
#service sendmail stop
Clear outgoing task
#rm -rf /var/spool/mqueue/*
start-up sendmail service
#service sendmail start
- No forwarding , Enable blacklist
modify postfix Configuration file for main.cf
#vim /etc/postfix/main.cf
take myhostname Point to the domain name of the mail service
myhostname = mail.xiabian.com
mydomain The parameter points to the root domain
mydomain = xiabian.com
myorigin Point to mydomain
myorigin = $mydomain
mydestination Point to mydomain
mydestination = $mydomain
To monitor all IP
inet_interfaces = all
Set to trust only this machine
mynetworks_style = host
To configure mydomain To be able to be Postfix forward
relay_domains = $mydomain
Control the sending of mail
Mail from foreign domain to local domain , Receive all
Mail from local domain to foreign domain , Only local sending is allowed
Foreign domain to foreign domain mail , Reject send
Set sender rules , Allow local domain addresses , And refuse sender_access The sender contained in the file
Prevent other users from outside to [email protected] Send email as , However, logging in to this computer and sending it again will not be affected
Rule 1 permit_mynetworks Is to allow local login users to send mail
smtpd_sender_restrictions = permit_mynetworks, check_sender_access
hash:/etc/postfix/sender_access, permit
/etc/postfix/sender_access The content of
xiabian.com REJECT
Set recipient rules , Allow local domain addresses , And allow recipient_access The recipient included in the document
smtpd_recipient_restrictions = permit_mynetworks, check_recipient_access
hash:/etc/postfix/recipient_access, reject
/etc/postfix/recipient_access The content of
The foreign domain can only be sent to the following two Email Address , Any other address will be rejected , Send to this machine but not affected by this machine
[email protected] OK
[email protected] OK
use postmap Generate hash File format
#postmap sender_access
#postmap recipient_access
start-up Postfix
#/etc/init.d/postfix start
版权声明
本文为[Mu Meiwen]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204230542192433.html
边栏推荐
- Total score of [Huawei machine test] (how to deal with the wrong answer? Go back once to represent one wrong answer)
- Pytorch学习记录(四):参数初始化
- 2-软件设计原则
- mysql如何将存储的秒转换为日期
- idea插件---背景播放歌曲
- Pilotage growth · ingenuity empowerment -- yonmaster developer training and pilotage plan is fully launched
- Pytorch学习记录(十二):学习率衰减+正则化
- filebrowser实现私有网盘
- The official website of UMI yarn create @ umijs / UMI app reports an error: the syntax of file name, directory name or volume label is incorrect
- delete和truncate
猜你喜欢
PyQy5学习(四):QAbstractButton+QRadioButton+QCheckBox
线程的底部实现原理—静态代理模式
lambda表达式
解决报错:ImportError: IProgress not found. Please update jupyter and ipywidgets
域内用户访问域外samba服务器用户名密码错误
delete和truncate
字符串(String)笔记
图解numpy数组矩阵
Solve the error: importerror: iprogress not found Please update jupyter and ipywidgets
2-软件设计原则
随机推荐
PyQy5学习(二):QMainWindow+QWidget+QLabel
自定义异常类
Postfix变成垃圾邮件中转站后的补救
XXL job pit guide XXL RPC remoting error (connect timed out)
实操—Nacos安装与配置
Pytorch学习记录(四):参数初始化
PreparedStatement防止SQL注入
Meta annotation (annotation of annotation)
Common protocols of OSI layer
POI generates excel and inserts pictures
金蝶EAS“总账”系统召唤“反过账”按钮
一文读懂当前常用的加密技术体系(对称、非对称、信息摘要、数字签名、数字证书、公钥体系)
Pytorch学习记录(十):数据预处理+Batch Normalization批处理(BN)
图解numpy数组矩阵
Multithreading and high concurrency (2) -- detailed explanation of synchronized usage
数字图像处理基础(冈萨雷斯)一
Software architecture design - software architecture style
Anaconda
POI exports to excel, and the same row of data is automatically merged into cells
Typescript interface & type rough understanding