Top Description Fields Constructors Methods
org.wildfly.common.xml

pack-priv final Class FactoryConstants

extends Object
Class Inheritance

Constants to configure the factories. OWASP XML External Entity Prevention Cheatsheet
Author
Boris Unckel
Since
1.6.0.Final

Field Summary

Modifier and TypeField and Description
public static final String
APACHE_DISALLOW_DOCTYPE_DECL

This is the PRIMARY defense.

public static final String
APACHE_LOAD_EXTERNAL_DTD

Disable external DTDs as well.

public static final String
XML_EXTERNAL_GENERAL_ENTITIES

If you can't completely disable DTDs, then at least do the following.

public static final String
XML_EXTERNAL_PARAMETER_ENTITIES

This feature has to be used together with the previous one(external-general-entities), otherwise it will not protect you from XXE for sure Do not include external parameter entities or the external DTD subset.

Constructor Summary

AccessConstructor and Description
private
FactoryConstants()

No instance.

Method Summary

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

APACHE_DISALLOW_DOCTYPE_DECLback to summary
public static final String APACHE_DISALLOW_DOCTYPE_DECL

This is the PRIMARY defense. If DTDs (doctypes) are disallowed, almost all XML entity attacks are prevented Xerces 2 only:

APACHE_LOAD_EXTERNAL_DTDback to summary
public static final String APACHE_LOAD_EXTERNAL_DTD

Disable external DTDs as well.

XML_EXTERNAL_GENERAL_ENTITIESback to summary
public static final String XML_EXTERNAL_GENERAL_ENTITIES

If you can't completely disable DTDs, then at least do the following. This feature has to be used together with the following one (external-parameter-entities), otherwise it will not protect you from XXE for sure Do not include external general entities. Xerces 1:

XML_EXTERNAL_PARAMETER_ENTITIESback to summary
public static final String XML_EXTERNAL_PARAMETER_ENTITIES

This feature has to be used together with the previous one(external-general-entities), otherwise it will not protect you from XXE for sure Do not include external parameter entities or the external DTD subset.

Constructor Detail

FactoryConstantsback to summary
private FactoryConstants()

No instance.