dkim redhat
  • instalar os pacotes:
    opendkim opendkim-libs
    
  • gerar a chave:
    mkdir /etc/opendkim/lbr.com.br
    cd /etc/opendkim/lbr.com.br
    opendkim-genkey -t -s mail -d lbr.com.br
    chown opendkim.opendkim mail.private
    
  • editar: /etc/opendkim.conf
    Mode  sv
    #KeyFile  /etc/opendkim/keys/default.private
    KeyTable /etc/opendkim/KeyTable
    SigningTable   refile:/etc/opendkim/SigningTable
    ExternalIgnoreList   refile:/etc/opendkim/TrustedHosts
    InternalHosts  refile:/etc/opendkim/TrustedHosts
    
  • editar: /etc/opendkim/KeyTable
    lbr.com.br lbr.com.br:mail:/etc/opendkim/lbr.com.br/mail.private
    
  • editar: /etc/opendkim/SigningTable
    *@lbr.com.br lbr.com.br
    
  • copiar o arquivo para a pasta do dkim:
    cp mail.private /etc/mail/dkim.key
    
  • Editar o DNS e adicionar a lina do mail.txt
  • Editar o /etc/postfix/main.cf
    # DKIM
    milter_default_action = accept
    milter_protocol = 2
    smtpd_milters = inet:localhost:8891
    non_smtpd_milters = inet:localhost:8891
    
IP
3.229.142.91