<html><head><meta http-equiv="Content-Type" content="text/html charset=iso-8859-1"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><div><br></div><div>JDOM (and other processors) should allow such names. It shouldn't be a configuration option.</div><div><br></div><div>"Reserved" means (I believe) "reserved for use by W3C in current or future standards". Therefore a W3C standard could come out next week that defines a legitimate use of the name "XMLFault". You would want JDOM applications to work with such documents.</div><div><br></div><div>Pragmatically, such names are in common use by users who haven't read the admonition against them, and since most software in the processing chain allows them, it's awkward for everyone if the data then hits a processor that doesn't.</div><div><br></div><div>Michael Kay</div><div>Saxonica</div><div><br></div><br><div><div>On 13 Mar 2014, at 12:51, Rolf <<a href="mailto:jdom@tuis.net">jdom@tuis.net</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite">
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
<div bgcolor="#FFFFFF" text="#000000">
An issue has been opened against JDOM:
<a class="moz-txt-link-freetext" href="https://github.com/hunterhacker/jdom/issues/126">https://github.com/hunterhacker/jdom/issues/126</a><br>
<br>
The basic issue is the following: The input XML document contains:<br>
<br>
<span class="nt"><XMLFault:XMLFault></span>...<span class="nt"></XMLFault:XMLFault><br>
<br>
And the namespace XMLFault is declared somewhere....<br>
<br>
According to the XML specification, the namespace prefix is not
allowed to start with the letters XML (in any case, upper, or
lower).<br>
<br>
JDOM is not allowing this to happen, and failing to process/load
the document.<br>
<br>
Unfortunately, the specification actually says:<br>
<br>
</span>
<blockquote>
<div class="constraint"><p class="prefix"><a id="xmlReserved" name="xmlReserved"><b>Namespace
constraint: Reserved Prefixes and Namespace Names</b></a></p>
<a id="xmlReserved" name="xmlReserved"><p>
The prefix <b>xml</b> is by definition bound to the
namespace name
<code>http://www.w3.org/XML/1998/namespace</code>. It
<em class="RFC2119" title="MAY in RFC 2119 context">MAY</em>,
but need not, be
declared, and <em class="RFC2119" title="MUST NOT in RFC
2119 context">MUST NOT</em>
be
bound to any other namespace name. Other prefixes
<em class="RFC2119" title="MUST NOT in RFC 2119 context">MUST
NOT</em>
be bound to this namespace
name,
and it
<em class="RFC2119" title="MUST NOT in RFC 2119 context">MUST
NOT</em>
be declared as the default namespace.
</p><p>
The prefix <b>xmlns</b> is used only to declare namespace
bindings and is by
definition bound to the namespace name
<code>http://www.w3.org/2000/xmlns/</code>. It
<em class="RFC2119" title="MUST NOT in RFC 2119 context">MUST
NOT</em>
be declared
.
Other prefixes
<em class="RFC2119" title="MUST NOT in RFC 2119 context">MUST
NOT</em>
be bound to this namespace name,
and it
<em class="RFC2119" title="MUST NOT in RFC 2119 context">MUST
NOT</em>
be declared as the default namespace.
Element names
<em class="RFC2119" title="MUST NOT in RFC 2119 context">MUST
NOT</em>
have the prefix <code>xmlns</code>.
</p><p>
All other prefixes beginning with the three-letter sequence
x, m, l,
in any case combination, are reserved. This means that:
</p>
<ul>
<li><p>users <em class="RFC2119" title="SHOULD NOT in RFC
2119 context">SHOULD NOT</em> use them except as
defined by later specifications</p>
</li>
<li><p>processors
<em class="RFC2119" title="MUST NOT in RFC 2119 context">MUST
NOT</em>
treat them as fatal errors.</p>
</li>
</ul>
</a></div>
</blockquote>
<span class="nt"><br>
JDOM is a processor, and it's treating this as a fatal error.<br>
<br>
How should this be fixed? Suggestions?<br>
<br>
As far as I can tell the only place needed to change the code is
in the Verifier, but, should it simply allow the prefixes, or
should it be a 'configurable' setting?<br>
<br>
Rolf<br>
<br>
<br>
<br>
</span>
</div>
_______________________________________________<br>To control your jdom-interest membership:<br><a href="http://www.jdom.org/mailman/options/jdom-interest/youraddr@yourhost.com">http://www.jdom.org/mailman/options/jdom-interest/youraddr@yourhost.com</a></blockquote></div><br></body></html>