jaxp
  1. jaxp
  2. JAXP-71

when XMLInputFactory IS_VALIDATING is false, DTD is still loaded

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Works as designed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      If the IS_VALIDATING property is set to "false" in an XMLInputFactory, and then an input stream is created and an XML document with a <DOCTYPE> element is read in that references an external URL for the DTD, the DTD is loaded from the URL even though it is not needed.

      The parser should skip loading the DTD if it is not needed.

        Activity

        Hide
        Joe Wang added a comment -

        Validating != Support DTD. Refer to http://java.net/jira/browse/SJSXP-9 and http://java.net/jira/browse/SJSXP-50, you may use the added property to skip external DTD:

        xif.setProperty("http://java.sun.com/xml/stream/properties/ignore-external-dtd",Boolean.TRUE);

        Show
        Joe Wang added a comment - Validating != Support DTD. Refer to http://java.net/jira/browse/SJSXP-9 and http://java.net/jira/browse/SJSXP-50 , you may use the added property to skip external DTD: xif.setProperty("http://java.sun.com/xml/stream/properties/ignore-external-dtd",Boolean.TRUE);

          People

          • Assignee:
            Joe Wang
            Reporter:
            Tom Mueller
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: