歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
Linux教程網 >> Linux綜合 >> Linux資訊 >> Linux文化 >> 如何設定拒收大型郵件

如何設定拒收大型郵件

日期:2017/2/27 12:20:51   编辑:Linux文化

如何在Server上設定,如果外部寄來的電郵超過限制的大小就拒收呢?你可以修改/etc/sendmail.cf
Mlocal, P=/bin/mail, F=lsDFMrmn, S=10, R=20/40,
Maxsize=1000000,
A=mail -d $u
Mprog, P=/usr/local/sendmail/smrsh, F=lsDFMeu, S=10, R=20/40, D=$z:/,
Maxsize=1000000,
A=sh -c $u

This limits incoming mail processed by by smrsh and /bin/mail to 1 million bytes.

You can do the same with the Mstmp, Mesmtp, and Mrelay statements to limit the size of outgoing mail as well.


Copyright © Linux教程網 All Rights Reserved