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 / 问题 / 401900
Accepted
Frank
Frank
Asked: 2012-06-25 22:19:37 +0800 CST2012-06-25 22:19:37 +0800 CST 2012-06-25 22:19:37 +0800 CST

Amavis / Altermime - 动态电子邮件签名(免责声明)

  • 772

我正在使用amavis、postfix、dovecot运行基本的 iredmail 安装。我想使用免责声明功能自动附加免责声明(在我们的例子中是签名)。

这样做的原因是客户端(ipad、outlook 等)不必配置签名设置,而且我们对发布的实际签名有公司控制权。

代替:

'[email protected]' => 'boss.domain.com.txt'

我想去

%mailbox + ‘@’ + %domain =>  %mailbox + “.” + %domain + ‘.txt’

这样我们就可以简单地使用脚本来生成.txt/.htm签名文件,只使用 mysql / php。

postfix email-server amavis
  • 1 1 个回答
  • 7283 Views

1 个回答

  • Voted
  1. Best Answer
    Frank
    2012-06-30T23:33:01+08:002012-06-30T23:33:01+08:00

    已在 Amavis 用户组上解决...谢谢 Mark Martinec 需要两个更改:

    在 /etc/amavis/conf.d/50-user 中添加:

    ################## ---- CUSTOM SIGNATURES AS DISCLAIMERS ------- ###############################
    # uses altermime to insert a different signatue per users
    # signatures are located in teh /etc/postfix/signatures/ directory
    # also needs a small change to amavisd code:
    # nano /usr/sbin/amavisd-new  - $disclaimer_options = untaint($opt);  (add the "untaint" word before ($opt)
    # each user needs two signatures (html / txt)   user.domain.com.txt user.domain.com.html
    
    
      $altermime = '/usr/bin/altermime';
    
      $defang_maps_by_ccat{+CC_CATCHALL} = [ 'disclaimer' ];
      @disclaimer_options_bysender_maps = ( { '.' => '$3.$5' } );
      @altermime_args_disclaimer = qw(--disclaimer=/etc/postfix/signatures/_OPTION_.txt --disclaimer-html=/etc/postfix/signatures/_OPTION_.html --force-for-bad-html);
    
    
    ################## ---- END CUSTOM SIGNATURES AS DISCLAIMERS ------- ###############################
    

    确保允许免责声明未被注释掉 => 1

    $policy_bank{'MYNETS'} = {   # mail originating from @mynetworks
      originating => 1,  # is true in MYNETS by default, but let's make it explicit
      os_fingerprint_method => undef,  # don't query p0f for internal clients
      allow_disclaimers => 1,  # enables disclaimer insertion if available
    };
    

    对 Altermi 做一个小改动:

    nano /usr/sbin/amavisd-new  - $disclaimer_options = untaint($opt);  (add the "untaint" word before ($opt)
    

    重新启动 Amavis(可能必须终止进程)

    • 5

相关问题

  • Postfix 在特定端口上接受邮件

  • 让 Postfix 以两种方式处理垃圾邮件

  • Postfix 或 exim:自动/程序化和转发电子邮件设置

  • 后缀电子邮件地址

  • 什么是最好的开源电子邮件解决方案包

Sidebar

Stats

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

    新安装后 postgres 的默认超级用户用户名/密码是什么?

    • 5 个回答
  • Marko Smith

    SFTP 使用什么端口?

    • 6 个回答
  • Marko Smith

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

    • 9 个回答
  • Marko Smith

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

    • 3 个回答
  • Marko Smith

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

    • 15 个回答
  • Martin Hope
    Tom Feiner 如何按大小对 du -h 输出进行排序 2009-02-26 05:42:42 +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