IBM Support

"Forbidden external reference" error and controlling external DTD/entity references



The DataPower Gateway returns an error: "Forbidden external reference encountered while parsing XML. External DTD/entity references are no longer allowed by default." This can happen while configuring a DataPower service or during XML schema validation.


The WSDL or schema file in use contains external DTD/entity references. Such references are disallowed by the device by default for security reasons.

Resolving The Problem

The XML Manager in use by the service (such as a Web Service Proxy or Multi-Protocol Gateway) includes a property that controls the use of external references. To allow the use of such references, it is necessary to change the setting of this property.

The property, called XML External Reference Handling, is set to Forbid by default. As a workaround, change the property to Allow and apply the changes. The property options are as follows:

    XML External Reference Handling
    Select the special handling for input documents that contain external references, such as an external entity or external DTD definition.
    • Forbid

    • Forbids external references. The parser stops when the document contains external references.
    • Ignore

    • Accesses and resolves external references, but replaces each for further processing with an empty string.
    • Allow

    • The parser resolves all external references.

[{"Product":{"code":"SS9H2Y","label":"IBM DataPower Gateway"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"General","Platform":[{"code":"PF009","label":"Firmware"}],"Version":"6.0.0;6.0.1;7.0.0;7.1;7.2","Edition":"Edition Independent","Line of Business":{"code":"LOB45","label":"Automation"}}]

Document Information

Modified date:
08 June 2021