The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Please help with SPF record

Discussion in 'E-mail Discussions' started by iLLuSi0nS, Jan 23, 2008.

  1. iLLuSi0nS

    iLLuSi0nS Active Member

    Joined:
    Jun 9, 2007
    Messages:
    43
    Likes Received:
    0
    Trophy Points:
    6
    I have tried and tried and tried. My hosting company tells me i need a spf record but i knew that 4 months ago when hotmail and yahoo would reject my mail, but no one can really help me with setting one up.

    I have a VPS server . My dns hostname is mydomain.hosted-servers.net

    I understand i am suppose to go to openspf.com and use the wizard to guide me, but i can only answer the first 2 questions and the rest are just to confusing.

    Also, do i really have to input a spf record for every domain name i have on my server? what if i have 5 thousand...i have to manually input a spf record for every domain? there has to be a easier way.

    this is what the wizard generated for me but i dont think it is right, and what about IP address, shouldnt there be a IP address somewhere in the spf record?

    mydomain.com. IN TXT "v=spf1 a mx ~all"

    and i read that since i am stationary and dont really use any other server to send mail except my own, i should have -all instead of ~all am i right? I have a feeling my main IP should be in that record but dont know if it should or where it would go. Thanks
     
  2. AlexV.

    AlexV. Well-Known Member

    Joined:
    Jun 15, 2006
    Messages:
    212
    Likes Received:
    1
    Trophy Points:
    16
  3. iLLuSi0nS

    iLLuSi0nS Active Member

    Joined:
    Jun 9, 2007
    Messages:
    43
    Likes Received:
    0
    Trophy Points:
    6
    I have read all those articles, what i want to know is, if i have 200 domains, i have to edit every single one of the domains? there has to be a better way...no?
     
  4. SuperBaby

    SuperBaby Well-Known Member

    Joined:
    Nov 27, 2003
    Messages:
    331
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Thailand
    cPanel Access Level:
    Website Owner
    Twitter:
    I am curious to know the answer too. But I only have 35 accounts.
     
  5. sparek-3

    sparek-3 Well-Known Member

    Joined:
    Aug 10, 2002
    Messages:
    1,383
    Likes Received:
    23
    Trophy Points:
    38
    cPanel Access Level:
    Root Administrator
    How are you sending out the mail? The SPF record is dependent on the domain of the envelope-sender of those messages.

    If you are sending out the messages through a PHP or CGI script on your account, then unless you are specifying a different envelope-sender, then the message is likely enveloped from the server's hostname. That DNS record is what would need to have an SPF record.

    If you are sending out mail from an e-mail client, then the envelope sender is likely your domain name and each domain name would need to have an SPF record.

    As far as using the ~all mechanism versus -all I have heard both ways. Personally, I like the -all method, but this is dependent on you specifying a solid SPF record. You have to know what IPs, Hosts, or ISPs are allowed to send mail from your domain name. If you don't know that, then you don't need to be using the -all method, and I would question whether or not if you need an SPF record.

    There are basically three options for the all mechanism, ?all, ~all, -all.

    The ?all method is useless to me because this is like saying, "I think these are all the servers that send out mail from this domain, but I'm not sure, you should also accept mail from other servers just to be safe." I suppose if you are setting up an SPF record just to have an SPF record, then this might work. I'm not sure how this is beneficial to any recipient server that receives mail from your domain name.

    The ~all method states that the list of IPs and hosts in the SPF record should be all, but any mail from any other server should also be accepted and flagged as spam.

    The -all method says that the defined IPs and hosts in the SPF record are all that should be sending mail from this domain. If a recipient server receives a message from this domain and it is not from an IP or host listed in the SPF record, disregard that message because its a forgery. To me this is the only option that really makes SPF worth it.
     
  6. AndyReed

    AndyReed Well-Known Member
    PartnerNOC

    Joined:
    May 29, 2004
    Messages:
    2,222
    Likes Received:
    3
    Trophy Points:
    38
    Location:
    Minneapolis, MN
    writing a shell or Perl script is the answer.
     
  7. agressor

    agressor Active Member

    Joined:
    May 15, 2005
    Messages:
    34
    Likes Received:
    0
    Trophy Points:
    6
    damn, why cpanel team no give a solution by update.. i have 7 server with problem delivering to hotmail.. about the solution for spf do this

    for i in `ls /var/cpanel/users` ;do /usr/local/cpanel/bin/spf_installer $i ;done


    i have right SPF i check this in
    http://www.microsoft.com/mscorp/safety/content/technologies/senderid/wizard/Default.aspx

    i have other server with DirectAdmin and this deliver right to hotmail with hostname as node of one server with cpanel.
     
  8. UBERHOST

    UBERHOST Well-Known Member

    Joined:
    Jan 13, 2008
    Messages:
    102
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    California, US
    Hmm, can the SPF text be set in the zone template?
     
  9. SecFilterEngine

    Joined:
    Feb 1, 2008
    Messages:
    6
    Likes Received:
    0
    Trophy Points:
    1
    UBERHOST,

    Yes, Main >> DNS Functions >> Edit Zone Templates >> standard >> edit >> type in :
    %domain%. IN TXT v=spf1 a -all <--- can be changed to what you want it to be .

    HTH
     
  10. UBERHOST

    UBERHOST Well-Known Member

    Joined:
    Jan 13, 2008
    Messages:
    102
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    California, US
    Thanks mate.
     
    #10 UBERHOST, Feb 2, 2008
    Last edited: Feb 2, 2008
  11. Jan.

    Jan. Registered

    Joined:
    Dec 2, 2009
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    ~all SPF record

    I am using cPanel 11.25.0-CURRENT (cPanel Pro 1.0 (RC1) header image says cPanel accelerated2) and don't know how to set an SPF record with the ~all. I do not have access to WHM.

    I have tried numerous times but it always makes use of the -all without any option to change it. Help!
     
Loading...

Share This Page