9
4
The TXT record for my domain currently has a legal disclaimer and terms and conditions. They were added some time ago due to spammers and other miscreants (to give me legal traction if I ever needed it).
I need to add a more information which is distinct from the first. According to RFC 1035, 3.3.14:
3.3.14. TXT RDATA format
+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
/ TXT-DATA /
+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
where:
TXT-DATA One or more <character-string>s.
TXT RRs are used to hold descriptive text. The semantics of the text
depends on the domain where it is found.
How, precisely, is the second (or third) string added? What is/are the delimiters of TXT-DATA?
Or do I add a second (or third) TXT record? Are multiple TXT records even allowed?
I think it’s easy and perfectly valid to have multiple TXT records for the same name, using one of them for SPF. RFC 7208 section 4.5 states that records not starting with
– Martin – 2015-11-26T18:08:33.003v=spf1
should be ignored.What is the binary delimiter in the packet? – CoolAJ86 – 2017-10-19T17:33:53.847
The strings are neither concatenated, nor do they result in multiple TXT records - there can be multiple txt records with multiple separate strings, and concatenating them would be wrong for some applications. – Remember Monica – 2018-04-12T08:34:20.537
@MarcLehmann: your comment makes no sense. Strings can concatenated (e.g. using multiline form as described above), but there could be multiple TXT records (perhaps using those long strings). Gist of this answer is that using multiple TXT records is not recommended, as it may confuse tools which only expect 1 TXT record. – mvp – 2018-04-12T17:55:00.383
Strings can be concatenated, but strings in TXT records aren't concatenated, and concatenating them is generally wrong, and no known implementation does that. The strings in a TXT record are also NEVER randomized, and will basically never read as in your example. Your answer answers the question about syntax, but is wrong, confusing or misleading in almost every other detail. – Remember Monica – 2018-04-13T10:57:10.683
@CoolAJ86 there is no delimiter, dns uses counted strings, so the strings can contain any byte values, including zero, although some very buggy implementations such as microsoft dns might corrupt them in transit. – Remember Monica – 2018-04-13T10:59:01.137
Just to clarify this further - TXT records can contain multiple string fragments, and these string fragments are not concatenated or reordered but stay distinct when transferred over the network. The examples given in this answer do not give identical outcome as trying it out will reveal. – Remember Monica – 2018-04-13T11:01:27.663
@MarcLehmann: please read this https://kb.isc.org/article/AA-00356/0/Can-I-have-a-TXT-or-SPF-record-longer-than-255-characters.html.
– mvp – 2018-04-13T18:32:05.170@mvp That kb article is correct and agrees with me, but is probably a bit sloppily worded which is why it might confuse you - note that it explicitly talks about concatenation of SPF records, not DNS TXT records in general, and even says that simple concatenation is not correct in general. Apart from that, random articles on the web have little relevance on DNS, which is defined by a collection of RFCs (or STDs), not random web pages. – Remember Monica – 2018-05-02T04:06:34.157
OK, so I finally got a chance to revisit this.... A popular SPF checker cannot handle the multiple strings in a single TXT record; nor can the SPF parser at
– jww – 2014-01-31T01:41:57.910check-auth@verifier.port25.com
(its an email address, and it returns an automated report).