Bugzilla – Bug 86
zonec cannot handle many characters (&, # [)
Last modified: 2004-07-28 13:25:41 CEST
We are secondary for zones that were compiled with nsd 1 but cannot be compiled
with nsd 2:
ERR: Line 1482 in secondary/XXX.fr: Unknown character seen - is this a zonefile?
However, the characters, although strange (& or # because people thought it was
the comment character) seems legal (RFC 1035, 3.1. Name space definitions) even
if they do not comply with the "preferred syntax" mentioned in the RFC.
IMHO, the following definition in zlexer.lex is broken. It is neither the
"preferred syntax" defined in RFC 1035 nor the full syntax (the RFC says "labels
can contain any 8 bit values in octets that make up a label") :
Note that RFC 2181, "Clarifications to the DNS Specification" speaks even more
clearly than RFC 1035:
11. Name syntax
The DNS itself places only one restriction on the particular labels that can be
used to identify resource records. That one restriction relates to the length
of the label and the full name.
Implementations of the DNS protocols must not place any restrictions
on the labels that can be used. In particular, DNS servers must not
refuse to serve a zone because it contains labels that might not be
acceptable to some DNS client programs.
Created attachment 20 [details]
adds: #%&^? to ZONESTR
> adds: #%&^? to ZONESTR
It would still violate RFC 1035 and 2181 which clearly says that *any* 8bits
character is allowed, even spaces (when escaped with \ which works on BIND).
And not in NSD...
% dig @localhost -p 5353 " bla.miek.nl"
;; QUESTION SECTION:
;\032bla.miek.nl. IN A
;; ANSWER SECTION:
\032bla.miek.nl. 3600 IN A 192.168.1.2