Package org.apache.ofbiz.base.util
Class UtilCodec.HtmlEncoder
java.lang.Object
org.apache.ofbiz.base.util.UtilCodec.HtmlEncoder
- All Implemented Interfaces:
UtilCodec.SimpleEncoder
- Enclosing class:
- UtilCodec
-
Field Summary
Modifier and TypeFieldDescriptionstatic final org.owasp.html.PolicyFactory
static final org.owasp.html.PolicyFactory
-
Constructor Summary
-
Method Summary
-
Field Details
-
PERMISSIVE_POLICY
public static final org.owasp.html.PolicyFactory PERMISSIVE_POLICY -
BIRT_FLEXIBLE_REPORT_POLICY
public static final org.owasp.html.PolicyFactory BIRT_FLEXIBLE_REPORT_POLICY
-
-
Constructor Details
-
HtmlEncoder
public HtmlEncoder()
-
-
Method Details
-
encode
- Specified by:
encode
in interfaceUtilCodec.SimpleEncoder
-
sanitize
Deprecated.Usesanitize(String, String)
instead- Specified by:
sanitize
in interfaceUtilCodec.SimpleEncoder
-
sanitize
This method will start a configurable sanitizing process. The sanitizer can be turns off through "sanitizer.enable=false", the default value is true. It is possible to configure a custom policy using the properties "sanitizer.permissive.policy" and "sanitizer.custom.permissive.policy.class". The custom policy has to implementSanitizerCustomPolicy
.- Specified by:
sanitize
in interfaceUtilCodec.SimpleEncoder
- Parameters:
original
-contentTypeId
-- Returns:
- sanitized HTML-Code if enabled, original HTML-Code when disabled
- See Also:
-
sanitize(String, String)
instead