Преглед на файлове

Add spf arg to lower gmail false positive spam

pull/308/head
tfasano1 преди 11 месеца
committed by GitHub
родител
ревизия
e4ae00cd69
No known key found for this signature in database GPG ключ ID: B5690EEEBB952194
променени са 1 файла, в които са добавени 5 реда и са изтрити 1 реда
  1. +5
    -1
      emailwiz.sh

+ 5
- 1
emailwiz.sh Целия файл

@@ -347,10 +347,14 @@ for x in opendkim dovecot postfix fail2ban; do
systemctl enable "$x"
done

# In some cases, big name email services favor an spf record with certain mechanisms included.
# See http://www.open-spf.org/SPF_Record_Syntax
mailip=ip4:$(ping -c 1 $domain | grep -m1 -Eo '([0-9]+\.){3}[0-9]+')

pval="$(tr -d '\n' <"/etc/postfix/dkim/$domain/$subdom.txt" | sed "s/k=rsa.* \"p=/k=rsa; p=/;s/\"\s*\"//;s/\"\s*).*//" | grep -o 'p=.*')"
dkimentry="$subdom._domainkey.$domain TXT v=DKIM1; k=rsa; $pval"
dmarcentry="_dmarc.$domain TXT v=DMARC1; p=reject; rua=mailto:dmarc@$domain; fo=1"
spfentry="$domain TXT v=spf1 mx a:$maildomain -all"
spfentry="$domain TXT v=spf1 mx a:$maildomain ip4:$mailip -all"
mxentry="$domain MX 10 $maildomain 300"

useradd -m -G mail dmarc


Зареждане…
Отказ
Запис