You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Rohan Padhye (JIRA)" <ji...@apache.org> on 2019/01/25 00:52:00 UTC

[jira] [Created] (MNG-6577) pom.xml: Uncaught IllegalArgumentException when parsing unicode entity ref

Rohan Padhye created MNG-6577:
---------------------------------

             Summary: pom.xml: Uncaught IllegalArgumentException when parsing unicode entity ref 
                 Key: MNG-6577
                 URL: https://issues.apache.org/jira/browse/MNG-6577
             Project: Maven
          Issue Type: Bug
          Components: POM
    Affects Versions: 3.6.0, 3.5.4
            Reporter: Rohan Padhye


Sample Maven {{pom.xml}} below:
{code:java}
<project name="&#xFFFFFF;"></project>{code}
0xFFFFFF is not a valid Unicode codepoint. This leads to the following uncaught exception arising from plexus:
{code:java}
Caused by: java.lang.IllegalArgumentException at org.codehaus.plexus.util.xml.pull.MXParser.toChars (MXParser.java:4023) at org.codehaus.plexus.util.xml.pull.MXParser.parseEntityRef (MXParser.java:2727) at org.codehaus.plexus.util.xml.pull.MXParser.parseAttribute (MXParser.java:2522) at org.codehaus.plexus.util.xml.pull.MXParser.parseStartTag (MXParser.java:2218) at org.codehaus.plexus.util.xml.pull.MXParser.parseProlog (MXParser.java:1801) at org.codehaus.plexus.util.xml.pull.MXParser.nextImpl (MXParser.java:1698) at org.codehaus.plexus.util.xml.pull.MXParser.next (MXParser.java:1317) at org.apache.maven.model.io.xpp3.MavenXpp3ReaderEx.read (MavenXpp3ReaderEx.java:4417) at org.apache.maven.model.io.xpp3.MavenXpp3ReaderEx.read (MavenXpp3ReaderEx.java:598) at org.apache.maven.model.io.DefaultModelReader.read (DefaultModelReader.java:105) at org.apache.maven.model.io.DefaultModelReader.read (DefaultModelReader.java:82)
...{code}
I'm guessing the expected behavior is to throw an {{XMLPullParserException}} instead, to signal an unparsable entity.

Found using [JQF|https://github.com/rohanpadhye/jqf].



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)