المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : Installing SPF Record on cpanel server



A7med Baraka
03-14-2010, 12:47 AM
What is SPF?
Sender Policy Framework (SPF) is an attempt to control forged e-mail. SPF is not directly about stopping spam – junk email. It is about giving domain owners a way to say which mail sources are legitimate for their domain and which ones aren’t. While not all spam is forged, virtually all forgeries are spam. SPF was created in 2003 to help close loopholes in email delivery systems that allow spammers to “spoof” or steal your email address to send hundreds, thousands or even millions of emails illicitly.
More information about SPF can be found at http://www.openspf.org (http://www.openspf.org/Project_Overview)
Why do I want to have SPF records for my domains?
Many mail servers are now testing for the presence of SPF records so if you don’t have one your email will probably not be delivered to that server. A good example is Hotmail that is testing for SPF records since 2004.


for information about SPF you may see at http://www.openspf.org/Project_Overview
and to install it very easy
1. login using root to WHM
2. click on zone templates under dns
3. there’ll be 3 option, just choose 1 first
4. add this at the end of line

%domain%. IN TXT “v=spf1 a mx -all”and repeat for those 2 others templates.
by editing this, you will find every new account you create has a spf record automatically.
then how about my current domain ?
good question!
now we’re going to that step.
login to ssh using root and follow instruction bellow
1. nano add.spf
2. put this code and save it

for i in `ls /var/cpanel/users` ;do /usr/local/cpanel/bin/spf_installer $i ;done3. chmod 755 add.spf
4. ./add.spf
done!
by doing this all the account’s zone should be updated using spf record.
If you have nothing to do and want to do this 1 by 1 account, simply using code bellow.

/usr/local/cpanel/bin/spf_installer USERNAMEreplace USERNAME with the username you want to add the SPF record.