Exim and DKIM on debian

Discussion in 'Server Operation' started by michltm, Feb 21, 2016.

  1. michltm

    michltm New Member

    I have been following a tutorial : iodigitalsec.com/exim-dkim-and-debian-configuration/ to configure DKIM on debian.
    At the end I could verify my record with the command
    Code:
    [email protected]:/etc/exim4# host -t txt 27564764._domainkey.yourdomain.com
    which worked.
    But using mail-tester.com, it is said that my messages are not signed with DKIM. Also My mails dont arrive in a lot of webmails
    such as hotmail even if I have an SPF and 9/10 score on mail-tester.com

    Does it give ways to verify why my messages are not signed with DKIM?
     
  2. ztk.me

    ztk.me Active Member

    Are you using exim to send mail at all? Did you by chance send a test mail from terminal using mail-command ( those mails are often not coverd / signed ).
    What happens if you change
    Code:
    DKIM_DOMAIN = ${sg{${lc:${domain:$h_from:}}}{^www\.}{}} 
    https://www.debian-administration.org/article/718/DKIM-signing_outgoing_mail_with_exim4
    Just a few wild guesses since I'm not using exim - but I'd suggest checking / debuging logs
    http://www.exim.org/exim-html-current/doc/html/spec_html/ch-log_files.html
    15. Reducing or increasing what is logged
     
  3. michltm

    michltm New Member

    Thank your for the ideas. I am currently testing them, and will comment back when I have the results.
     
  4. michltm

    michltm New Member

    After many tries, I havent been able to configure the DKIM with Exim4. But I could do it using postfix (which is probably a bit easier, using this tuorial: https://www.digitalocean.com/commun...ix-as-a-send-only-smtp-server-on-ubuntu-14-04

    But sadly, having now a 10/10 score on mailtester-com dident lead to a better tolerance of webamils. So the problem must be somewhere else.

    So, despite having an an SPF and valid DKIM, my mail arrives
    -in spams with Gmail

    -doesn’t arrive at all with Hotmail and 1&1

    -arrive with no problems with Orange.

    I don’t know which way to look at, maybe it could have something to do with mx ?

    Here is my configuration, but first the mail-tester report:

    Score: 10/10

    -Your server 212.227.XXX.XXX is authentified to use [email protected]

    -Your server 212.227.XXX.XXX is authentified to use [email protected]

    -You DKIM signature is valid.

    -You dont send your emails from your own domain: we cant verify DMARC

    -Your server 212.227.XXX.XXX is correctly associated to mydomain.com

    -Your hostname mydomain.com is attached to a server.

    -Your server is not blacklisted.

    -Reverse DNS shows mydomain.com


    DNS parameters :

    Server of names 1&1

    A 212.227.XXX.XXX

    MX mx00.1and1.fr

    MX mx01.1and1.fr


    MX-record:

    Server email 1&1

    Php code to send mails :

    PHP:
      <?php

      ini_set
    'display_errors');

      
    error_reportingE_ALL );

      
    $headers "From: [email protected]\n";

      
    $headers .= "MIME-Version: 1.0\n";

      
    $headers .= "Reply-To:  <contact@ mydomain.com >\n";

     
    $to ="[email protected]";

    $subject ="Website subscription";

    $message ="Hi! \n Thanks for subscribing to mydomain.com. \n

    But in the best case I will end up in spams. It's a pitty. "
    ;

    mail($to,$subject,$message,$headers);

      echo 
    "Test email sent";

      
    ?>


    Thank in advance to the one who will avoid me new nights of insomnia!
     
  5. florian030

    florian030 ISPConfig Developer ISPConfig Developer

Share This Page