SPF record support

Discussion in 'Feature Requests' started by fbarcenas, Oct 25, 2014.

  1. fbarcenas

    fbarcenas Member

    There is record type for DNS called SPF. It would be nice if it could be added as a type, and the default template would atumatically fill it out for you. THis will help curb spam, thanks.
     
  2. edge

    edge Active Member Moderator

    Just enter the SPF data in the TXT entry.
    It's the same!
     
  3. florian030

    florian030 Well-Known Member HowtoForge Supporter

    You can add the SPF-Settings to a TXT-record. There is no need for a SPF-record.

    A TXT-Record can look like

    Code:
    example.com. 60      TXT        "v=spf1 mx -all"
    and could be added already to the template.

    This allows the server(s) listed in the MX-records to send mail for example.com. Otherwise the mail should not be acepted (or use ~ instead of - for softfail).

    There are a lot of more options (in general a MX-record has NOTHING to do with sending mail) avialble. Please see here.
     
  4. fbarcenas

    fbarcenas Member

    Additionally, I'm just stating that if it comes that way by default, there would be less domains for spammers to spoof.
     
  5. florian030

    florian030 Well-Known Member HowtoForge Supporter

    You can not setup such a record in the dns-wizard with default-values because you can´t know, which server will send mails for a domain.
     
  6. stef157

    stef157 Member

  7. till

    till Super Moderator Staff Member ISPConfig Developer

    As far as I know, the record type SPF is deprecated and TXT records should be used instead.
     
  8. florian030

    florian030 Well-Known Member HowtoForge Supporter

    Could please clarify the data-differnce between
    Code:
    example.com. IN TXT "v=spf1 +mx a:colo.example.com/28 -all"
    and
    Code:
    example.com. IN SPF "v=spf1 +mx a:colo.example.com/28 -all"
    You can store the same spf-informations in a txt and a spf-record so there is no need for using a spf-record.
     
  9. fbarcenas

    fbarcenas Member

    I thought it was the other way around. I throught putting the SPF record in the text field was depreciated. I thought a dedicated SPF record type was the new standard.
     
  10. fbarcenas

    fbarcenas Member

    Here is a snippet of information I found.

    http://mxtoolbox.com/problem/spf/spf-record-deprecated

    I guess putting the spf record into the TXT record is the correct way after all.

    Maybe it would be nice if ISPCONFIG included it in it's default dns wizard template. Since it's a good practice for everyone to have one.
     
    Last edited: Nov 13, 2014
  11. florian030

    florian030 Well-Known Member HowtoForge Supporter

    You can alreade add a TXT-Record for an existing dns-template.

    Code:
    TXT|{DOMAIN}.|v=spf1 mx -all|0|86400
    This requieres, that you defined the mx-Records in the right way:

    Code:
    MX|{DOMAIN}.|mx.server.com.|100|86400
    mx.server.com needs at least an A or AAAA-Record.
     
  12. budgierless

    budgierless Member HowtoForge Supporter

    can i use only the txt in my template, or is the mx needed also?
     
  13. florian030

    florian030 Well-Known Member HowtoForge Supporter

    you can use this record, if your maill-server is within the mx-record. With this record you can not send mails from ips, that do not belong to the mx-server.
     
  14. budgierless

    budgierless Member HowtoForge Supporter

    Your mx suggested record makes no sense to me, is it for a dedicated mail server? Or can this be applied to single server too?
    If so can the code be:
    MX|{DOMAIN}.|{IP} .|100|86400?
     
  15. till

    till Super Moderator Staff Member ISPConfig Developer

    Seems as if you mix up MX and SPF records, what you posted is a MX record, this thread here is about SPF records and what Florian posted above is a valid SPF record that should work for all single servers and also multiserver setups where the web node relays email trough the mail node.
     
  16. budgierless

    budgierless Member HowtoForge Supporter

    Yes I get it, regarding the SPF record in TXT form thats fine as i have used a that before in a other CP setup before ispconfig, I just got confused regarding the following MX code posted below the TXT, dose that have to be applied in-order to make the SPF/TXT work in ispconfig? if not then why is it mentioned in the post?
     
  17. till

    till Super Moderator Staff Member ISPConfig Developer

    The SPF records allows email sending from the server that is defined as MX of that zone. So you need a valid MX record in that domain to use the SPF.
     
  18. budgierless

    budgierless Member HowtoForge Supporter

    ok, so are you saying the MX record is not part or the dns zone template? if so could i add this to and template:
    MX|{DOMAIN}.|mx.{DOMAIN}.|100|86400
    would that work?
     
  19. till

    till Super Moderator Staff Member ISPConfig Developer

    Check your zone template if it has an MX record, if the mx record is missing, then add one, if the MX recod in your template is already there, then there is no need to add an additional one.
     
  20. budgierless

    budgierless Member HowtoForge Supporter

    Ok will check it out when i get home, but if it is not in the template, will my suggested MX syntax be ok to add to the template? as would be a shame to always have to add manually.
     

Share This Page