AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / server / 问题 / 33518
In Process
user8677
user8677
Asked: 2009-06-30 14:32:29 +0800 CST2009-06-30 14:32:29 +0800 CST 2009-06-30 14:32:29 +0800 CST

后缀跳过对授权 SMTP 的垃圾邮件检查

  • 772

有什么方法可以配置后缀以跳过那些经过 SMTP-AUTH 的 smtp 连接的垃圾邮件/防病毒检查?我想保留对外部 smtp 流量的所有标准检查,但对于发送电子邮件的本地用户,我想跳过反垃圾邮件/防病毒检查。

我的配置几乎标准配置有 Postfix + Amavisd + SpamAssassin + clamav。

提前致谢。先生

spam postfix spamassassin amavis
  • 3 3 个回答
  • 4145 Views

3 个回答

  • Voted
  1. Balázs Pozsár
    2009-06-30T15:09:07+08:002009-06-30T15:09:07+08:00

    在 main.cf 中,设置

    smtpd_data_restrictions = reject_unauth_pipelining,permit_sasl_authenticated,check_sender_access pcre:/etc/postfix/content_filter.pcre
    

    不要在 main.cf 中设置 content_filter=!

    /etc/postfix/content_filter.pcre 应该是这样的:

    /^/ FILTER smtp-amavis:[127.0.0.1]:10024
    

    别忘了跑

    postmap /etc/postfix/content_filter.pcre
    

    master.cf 应该是这样的:

    127.0.0.1:10025 inet n  -   n -   -  smtpd
        -o content_filter=
        -o local_recipient_maps=
        -o relay_recipient_maps=
        -o smtpd_data_restrictions=
        -o smtpd_restriction_classes=
        -o smtpd_client_restrictions=
        -o smtpd_helo_restrictions=
        -o smtpd_sender_restrictions=
        -o smtpd_recipient_restrictions=permit_mynetworks,reject
        -o mynetworks=127.0.0.0/8
        -o smtpd_error_sleep_time=0
        -o smtpd_soft_error_limit=1001
        -o smtpd_hard_error_limit=1000
    smtp-amavis unix -      -       n       -       16       lmtp
        -o lmtp_data_done_timeout=1200
        -o lmtp_send_vforward_command=yes
        -o disable_dns_lookups=yes
    

    希望这可以帮助。有关详细信息,请参阅http://www.postfix.org/postconf.5.html。

    • 1
  2. Mark
    2009-06-30T18:41:44+08:002009-06-30T18:41:44+08:00

    在您的 main.cf 文件中,假设您在smtpd_recipient_restrictions(或smtpd_data_restrictions/ smtpd_something_restrictions)中有垃圾邮件过滤器,请permit_sasl_authenticated在其他任何内容之前添加。这将在此过程中尽早接受经过身份验证的用户,而无需运行任何进一步的检查。smtpd_*_restrictions可能有一种方法可以使用类似条目的方式将垃圾邮件/病毒扫描包含在行中check_policy_service,该条目将检查 master.cf 中定义的服务。我目前使用它对所有邮件运行外部 spf 测试,但我希望它适用于其他检查。

    • 0
  3. Benny Pedersen
    2015-12-04T13:07:43+08:002015-12-04T13:07:43+08:00

    pcre文件不应被后映射。

    如果端口 25 未与 sasl auth 一起使用,则在 smtp 端口 25 中使用 content_filter 只会对 smtp auth 用户禁用它。

    配置起来并不难。

    • 0

相关问题

  • SmarterMail 中的反垃圾邮件过滤功能是否适用于分发列表?

  • 谁能推荐外围垃圾邮件过滤服务?[关闭]

  • 良好且免费的交换垃圾邮件过滤器[关闭]

  • 如何使用 Postfix 将邮件中继到另一台机器?

  • 针对大量邮件的 SMTP 服务的建议 [关闭]

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    SFTP 使用什么端口?

    • 6 个回答
  • Marko Smith

    从 IP 地址解析主机名

    • 8 个回答
  • Marko Smith

    如何按大小对 du -h 输出进行排序

    • 30 个回答
  • Marko Smith

    命令行列出 Windows Active Directory 组中的用户?

    • 9 个回答
  • Marko Smith

    Windows 中执行反向 DNS 查找的命令行实用程序是什么?

    • 14 个回答
  • Marko Smith

    如何检查 Windows 机器上的端口是否被阻塞?

    • 4 个回答
  • Marko Smith

    我应该打开哪个端口以允许远程桌面?

    • 9 个回答
  • Marko Smith

    什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同?

    • 3 个回答
  • Marko Smith

    如何确定bash变量是否为空?

    • 15 个回答
  • Martin Hope
    MikeN 在 Nginx 中,如何在维护子域的同时将所有 http 请求重写为 https? 2009-09-22 06:04:43 +0800 CST
  • Martin Hope
    Tom Feiner 如何按大小对 du -h 输出进行排序 2009-02-26 05:42:42 +0800 CST
  • Martin Hope
    0x89 bash中的双方括号和单方括号有什么区别? 2009-08-10 13:11:51 +0800 CST
  • Martin Hope
    kch 如何更改我的私钥密码? 2009-08-06 21:37:57 +0800 CST
  • Martin Hope
    Kyle Brandt IPv4 子网如何工作? 2009-08-05 06:05:31 +0800 CST
  • Martin Hope
    Noah Goodrich 什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同? 2009-05-19 18:24:42 +0800 CST
  • Martin Hope
    Brent 如何确定bash变量是否为空? 2009-05-13 09:54:48 +0800 CST
  • Martin Hope
    cletus 您如何找到在 Windows 中打开文件的进程? 2009-05-01 16:47:16 +0800 CST

热门标签

linux nginx windows networking ubuntu domain-name-system amazon-web-services active-directory apache-2.4 ssh

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve