Uploaded image for project: 'Teiid'
  1. Teiid
  2. TEIID-2911

Guard against external entity resolving

    XMLWordPrintable

    Details

      Description

      if applications that expose RESTEasy XML endpoints, add the following snippet to their web.xml file to disable entity expansion in RESTEasy:

      <context-param>
      <param-name>resteasy.document.expand.entity.references</param-name>
      <param-value>false</param-value>
      </context-param>

      Note that this <context-param> setting has precedence over <init-param>, and will override a contrary setting in an <init-param> element.

      However this is not sufficient for OData as OData4j is responsible for parsing the Atom feed. StaxXMLFactoryProvider2 simply creates XMLInputFactories without any options, thus they will perform external entity resolving by default. An issue will need to be opened against OData4j.

      For SQL/XML, the XMLType input factory needs to disable external entity resolving (via experimentation just setting the relevant property doesn't always work, so like other projects we'll set an XMLResolver, which does work).

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              rhn-engineering-shawkins Steven Hawkins
              Reporter:
              van.halbert Van Halbert (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: