[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [idn] ZWNJ



David Hopwood <david.hopwood@zetnet.co.uk> wrote:

> A related question is whether names that are returned in reverse
> lookups have to be nameprepped.

In my opinion, nameprep is for defining the equivalence between names,
and therefore it needs to be invoked only when comparing names.  I
see no advantage to perform nameprep before sending a name, and the
disadvantage is that it loses information that might be helpful to
humans.

There are two exceptions to that rule:  First, ACEs must always be
nameprepped, because the whole point of ACE is to be compatible with
old applications, which don't know about nameprep.  Second, non-ACE
DNS queries (not responses) should be nameprepped on the client as a
performance optimization, because that would always be the first thing
the server would do anyway (there is no human user on the server side to
lament the loss of information, and the client can retain the original
form).  If there are other protocols in which a server would always
apply nameprep to all incoming names and discard the original form, the
same argument could apply to them.  But in general, for non-ACE names, I
think nameprepped names should not be shipped around; nameprep should be
performed as part of the comparison operation.

AMC

P.S. Actually, the easiest way to compare two labels is to convert both
to ASCII (using nameprep, and ACE if necessary) and then compare using
the customary case-insensitive ASCII comparison.  This not only catches
the equivalence between two old-style labels, two ACE labels, and two
non-ASCII labels, but also handles the case where one label is non-ASCII
and the other is the corresponding ACE form, and the case where one
label is simple non-ACE ASCII and the other is a non-ASCII equivalent
form (using full-width Latin letters, for example).