Introduction
If you'd like to get the SPF/DKIM records for each domain and check them against what SPF/DKIM records the server has for that domain, the following commands will loop over every domain on the server for you.
This check will report whether the returned SPF/DKIM records match what is shown within the "Email Deliverability" interface of cPanel, at "Home / Email / Email Deliverability".
Procedure
As the root user, please run either or both of the following commands, depending on whether you want to validate your SPF and/or DKIM records.
To validate SPF records:
awk -F "==" '{print $1}' /etc/userdatadomains | while read DOMAIN USER; do uapi --user=$USER EmailAuth validate_current_spfs domain=${DOMAIN::-1};done
To validate DKIM records:
awk -F "==" '{print $1}' /etc/userdatadomains | while read DOMAIN USER; do uapi --user=$USER EmailAuth validate_current_dkims domain=${DOMAIN::-1};done
Comments
0 comments
Article is closed for comments.