27
2025
05
15:31:02

如何允许 .eml 电子邮件附件 How to permit .eml email attachments

cPanel / cPanel & WHM / Support Topics / Email

介绍

默认情况下,Exim会阻止带有.eml扩展名的附件以确保安全。本文提供了修改Exim配置以允许带有.eml扩展名的附件的步骤。

如果在 Exim 配置管理器中启用 Exim 附件过滤器,附加资源下的文章 "如何将某些附件加入 Exim 过滤器的白名单" 将需要使用来在那里允许 .eml 附件。

程序

  1. 以‘root’用户身份登录WHM。

  2. 导航到 "主页 / 服务配置 / Exim配置管理器."

  3. 点击"高级编辑器"标签。

  4. 向下滚动到"acl_not_smtp_mime"部分。

  5. 取消选择 "禁止使用的文件名_bl" 选项。

  6. 选择"自定义开始不为SMTP MIME"选项。

  7. 将以下内容粘贴到"custom_begin_not_smtp_mime"文本框中。

    # 拒收带有潜在危险附件的入站邮件# 使用参数值续写的文件名混淆技术可以绕过其他过滤器,但无法绕过这个拒绝
      日志消息 = 拒绝: 禁止的 \"$mime_filename\"
      条件 = ${如果匹配
      {${lc:$mime_filename}}
      {[.](ad[ep]|ba[st]|chm|cmd|com|cpl|crt|exe|hlp|hta|in[fs]|isp|jse?|lnk|md[be]|ms[cipt]|pcd|pif|reg|scr|sct|shs|url|vb[se]|ws[fhc])\$}}
      message = 附件文件名“$mime_filename”有禁止的扩展名。

    接受
  8. 向下滚动到"acl_smtp_mime"部分。

  9. 取消选择 "禁止使用的文件名_bl" 选项。

  10. 选择"自定义开始SMTP MIME"选项。

  11. 将以下内容粘贴到“custom_begin_smtp_mime”文本框中。

    # 拒收带有潜在危险附件的入站邮件# 使用参数值续写的文件名混淆技术可以绕过其他过滤器,但无法绕过这个拒绝
      日志消息 = 拒绝: 禁止的 \"$mime_filename\"
      条件 = ${如果匹配
      {${lc:$mime_filename}}
      {[.](ad[ep]|ba[st]|chm|cmd|com|cpl|crt|exe|hlp|hta|in[fs]|isp|jse?|lnk|md[be]|ms[cipt]|pcd|pif|reg|scr|sct|shs|url|vb[se]|ws[fhc])\$}}
      message = 附件文件名“$mime_filename”有禁止的扩展名。

    接受
  12. 向下滚动到页面底部。

  13. 点击"保存"按钮。

 



Introduction

By default, Exim blocks attachments with the .eml extension for security. This article provides the steps to modify the Exim configuration to allow attachments with the .eml extension.

If the Exim Attachments filter is enabled in Exim Configuration manager, the article under Additional Resources, "How to whitelist or allow certain attachments through the Exim filter" will need to be used to allow .eml attachments there as well.

Procedure

  1. Log into WHM as the ‘root’ user.

  2. Navigate to "Home / Service Configuration / Exim Configuration Manager."

  3. Click the "Advanced Editor" tab.

  4. Scroll down to the "acl_not_smtp_mime" section.

  5. Deselect the "disallowed_filenames_bl" option.

  6. Select the "custom_begin_not_smtp_mime" option.

  7. Paste the following into the "custom_begin_not_smtp_mime" textbox.

    # Reject inbound mail with potentially dangerous attachments
    # Obfuscation of file names using parameter value continuation evades other filters, but not this one
    
    deny
      log_message = DENY: disallowed \"$mime_filename\"
      condition = ${if match \
      {${lc:$mime_filename}} \
      {[.](ad[ep]|ba[st]|chm|cmd|com|cpl|crt|exe|hlp|hta|in[fs]|isp|jse?|lnk|md[be]|ms[cipt]|pcd|pif|reg|scr|sct|shs|url|vb[se]|ws[fhc])\$}}
      message = Attached file '$mime_filename' has disallowed extension.
    
    accept
  8. Scroll down to the "acl_smtp_mime" section.

  9. Deselect the "disallowed_filenames_bl" option.

  10. Select the "custom_begin_smtp_mime" option.

  11. Paste the following into the "custom_begin_smtp_mime" textbox.

    # Reject inbound mail with potentially dangerous attachments
    # Obfuscation of file names using parameter value continuation evades other filters, but not this one
    
    deny
      log_message = DENY: disallowed \"$mime_filename\"
      condition = ${if match \
      {${lc:$mime_filename}} \
      {[.](ad[ep]|ba[st]|chm|cmd|com|cpl|crt|exe|hlp|hta|in[fs]|isp|jse?|lnk|md[be]|ms[cipt]|pcd|pif|reg|scr|sct|shs|url|vb[se]|ws[fhc])\$}}
      message = Attached file '$mime_filename' has disallowed extension.
    
    accept
  12. Scroll down to the bottom of the page.

  13. Click the "Save" button.

 




推荐本站淘宝优惠价购买喜欢的宝贝:

image.png

本文链接:https://hqyman.cn/post/11364.html 非本站原创文章欢迎转载,原创文章需保留本站地址!

分享到:
打赏





休息一下~~


« 上一篇 下一篇 »

发表评论:

◎欢迎参与讨论,请在这里发表您的看法、交流您的观点。

请先 登录 再评论,若不是会员请先 注册

您的IP地址是: