maradns: parse cname and unknown raw records - #33
Merged
Conversation
msimerson
approved these changes
Aug 30, 2026
msimerson
approved these changes
Aug 30, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two test cases were disabled with
it.skip. Both hid real parser gaps.cnamewas missing from the set of type tokens the parser recognises, so a CNAME line was read as an A record.dnameandurihad the same problem. The dispatch switch already had cases for all three. None was ever reached, so all three threw:URIneeded one more thing. csv2 quotes the target, and those quotes are what stopexpandPercentfrom eating a percent-encoded URI, so they can only come off afterwards. The target now matches whatfromTinydnsproduces:A
RAWline with an unrecognised type id returned false and the record was discarded. It now returns anRR.UNKNOWNper RFC 3597. This changes output. A zone containing such a record now yields one more record than before. The fixture count moves from 40 to 41.A malformed type id still returns false.
RR.UNKNOWNvalidates the id and throwsinvalid DNS type: TYPENaN, so without that check a line that used to be skipped would end the parse instead.RR.UNKNOWNarrived in dns-resource-record 1.9.0. That is already the declared floor.