Mailsending ipv6 to Google-Mailservice fails

Discussion in 'Server Operation' started by muelli75, Aug 14, 2022.

Tags:
  1. odea

    odea New Member

    Hi, an update : my emails are still tagged as spam by gmail.
    I tried https://mxtoolbox.com, and checked the dkim lookup with odea.fr:default, the result is green...
    So I thought it was gmail the problem, but I checked with https://www.mail-tester.com and it says that my message is not signed with DKIM !
    In ispconfig, when I go to email / odea.fr, DKIM is generated, and I already added the TXT domain :
    upload_2023-8-19_23-9-52.png
    Here is the result of this host command :
    Code:
    $ host -t txt default._domainkey.odea.fr.
    default._domainkey.odea.fr descriptive text "v=DKIM1; t=s; p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDB05ZwrrM3RTIJeK3Q829KR9JfN/(cut)"
    I don't have "h=sha256;" and "s=*;", that wasn't generated by ispconfig, don't know if it's normal.
    I have no error message from gmail...
    I have a hard time to figure out if DKIM is well activated or not, for me it is, but not for mail-tester, and maybe (I don't know) not for gmail.
     
    Last edited: Aug 19, 2023
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    You can see in the mail source code of dkim is active or not. Look at the headers, if there is a dkim signature, then it's active. DNS is not relevant for signing, its only relevant for verifying the signature.
     
  3. odea

    odea New Member

    Indeed, no mention of DKIM in the emails, which is strange, because from an ispconfig point of view it should be active :
    upload_2023-8-20_10-22-8.png
     
  4. odea

    odea New Member

  5. till

    till Super Moderator Staff Member ISPConfig Developer

    That, of course, must make email signing fail.

    No. You need Amavis or Rspamd to sign messages with DKIM on your ISPConfig server. On a recent system, you should use Rspamd.
     
    ahrasis likes this.
  6. odea

    odea New Member

    I launched ispconfig_update.sh to have fresh config files.
    amavisd and clamav are running, I'm still under debian 9, so if i'm correct amavis will handle the spamassassin's filters.
    I still don't have dkim signature.
     
  7. odea

    odea New Member

    I figured out :
    I had to add manually an entry in /etc/amavis/conf.d/60-dkim
    Code:
    dkim_key('odea.fr', 'default', '/var/lib/amavis/dkim/odea.fr.private');
    I don't know why ispconfig doesn't add it by itself maybe a permission issue ? :
    Code:
    root@ns1:/etc/amavis/conf.d# ll
    total 68
    -rw-r--r-- 1 root root    1610 janv. 24  2016 01-debian
    -rw-r--r-- 1 root root     692 janv. 24  2016 05-domain_id
    -rw-r--r-- 1 root root     429 janv. 24  2016 05-node_id
    -rw-r--r-- 1 root root   20691 janv. 24  2016 15-av_scanners
    -rw-r--r-- 1 root root     717 janv. 24  2016 15-content_filter_mode
    -rw-r--r-- 1 root root    9538 janv. 24  2016 20-debian_defaults
    -rw-r--r-- 1 root root     573 janv. 24  2016 25-amavis_helpers
    -rw-r--r-- 1 root root    2130 janv. 24  2016 30-template_localization
    -rw-r----- 1 root amavis  3296 août  20 12:47 50-user
    -rw-r--r-- 1 root root     184 août  20 21:59 60-dkim
     
    Last edited: Aug 20, 2023
  8. odea

    odea New Member

    My emails are still tagged SPAM by gmail :/
    10/10 on mail-tester.com
    rDNS/PTR, SPF, DKIM, DMARC = OK
    For some domains on my server, emails are tagged spam (ex: vegan.fr), for some it's OK (ex: odea.fr). I compared headers of OK emails with tagged spam emails, and I see no difference.
    No domain are blacklisted (except UCEPROTECTL3 but it's the same for all domains, even those not tagged spam).
    I don't know where else to check other than directly contact gmail (which is almost impossible).
    Could I check something else ? I'm out of idea.
     
  9. odea

    odea New Member

    I just check with https://toolbox.googleapps.com/apps/checkmx/
    the results are very very strange !
    upload_2023-8-22_23-34-0.png
    I'm not sure for SPF : in red it's written : SPF needs to authorize Google's server to send emails to the domain.
    I'm very confused.
     
  10. till

    till Super Moderator Staff Member ISPConfig Developer

    I guess you might be using the wrong check tool. The tool is probably for checking if you delegated mail sending to Google (means you sue your domain for a gamil account instead of using your own mail system) and not to check if you are allowed to send to Google, as you definitely do not have to list Google in SPF.
     
  11. odea

    odea New Member

    Yes you're right ! I guest I'm trying too much things to find out the root cause of my problem...it's driving me crazy...
    So how can it be possible to have 10/10 at mail-tester, and no problem with mxtoolbox and still be tagged as spam by gmail ?
     
  12. till

    till Super Moderator Staff Member ISPConfig Developer

    Having set up your system correctly is no guarantee that mail services like Gmail will not flag your mail as spam. If your IP has a bad reputation, then it will take time to fix that. Also the content of your test email may get it flagged as spam if it is recognized as a test email. if you have an IPv4 and IPv6 address, then you can e.g. try to limit postfix to IPv4 only to see if this helps. And if you have not done that yet, sihn up for google postmaster tools https://postmaster.google.com and add your domain there.
     
  13. odea

    odea New Member

    Thanks for your time.
    My IP seems to be OK with mxtoolbox and other blacklist search website, maybe it's internal to Google.
    I try to send "test email" with "normal human content", but maybe it's not good enough.
    I'll try to send emails only with ipv4 with postfix.
    I already added one domain in postmaster.google.com, the problem from what I understood, is that it needs a huge amount of emails to starting to generate stats, so atm my dashboard has no data. I'll try to contact Google directly.
     

Share This Page