Skip to content

AlignedRdataFormatters::TXT() breaks Google site verification #117

@laszlof

Description

@laszlof

Since moving over to using this library for some of our DNS handling, we've notice that google site verification is now broken for new domains.

This appears to be due to the fact that the above mentioned method is splitting the TXT records at 40 characters, presumably just for easier readability.

This results in split strings in the resulting record. From what I can gather, they should be concat'ing these strings together, but that does not appear to be happening.

After further reading, I found RFC4408, section 3.1.3. However, this specific RFC only related to SPF-type TXT records, and not general validation records such as the one used for Google Site Verification.

I've illustrated the issue below:

$ dig franklaszlo.com txt +short
"google-site-verification=FNI0xUTGqcdI8YX" "xaPf_3mj33BYnNtY23ddD2Zl1ECc"
$ grep -C2 site-verification zones/f/franklaszlo.com 
; TXT RECORDS
@                   300   IN TXT   ( 
                                     "google-site-verification=FNI0xUTGqcdI8YX"
                                     "xaPf_3mj33BYnNtY23ddD2Zl1ECc"
                                   )

Screenshot 2023-07-21 at 10 31 59 AM

I'm not sure what the best fix here is, other than changing the split to be the max, 255 characters, for TXT records.

Let me know if you need further information

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions