Class EncodeTag

All Implemented Interfaces:
Serializable, BodyTag, IterationTag, JspTag, Tag

public class EncodeTag extends BodyTagSupport
Tag for writing properly XSS encoded text to the response using the OWASP ESAPI for supporting a number of encoding modes.
See Also:
  • Constructor Details

    • EncodeTag

      public EncodeTag()
  • Method Details

    • doEndTag

      public int doEndTag() throws JspException
      Description copied from class: BodyTagSupport
      Default processing of the end tag returning EVAL_PAGE.
      Specified by:
      doEndTag in interface Tag
      Overrides:
      doEndTag in class BodyTagSupport
      Returns:
      EVAL_PAGE
      Throws:
      JspException - if an error occurred while processing this tag
      See Also:
    • doStartTag

      public int doStartTag() throws JspException
      Description copied from class: BodyTagSupport
      Default processing of the start tag returning EVAL_BODY_BUFFERED.
      Specified by:
      doStartTag in interface Tag
      Overrides:
      doStartTag in class BodyTagSupport
      Returns:
      EVAL_BODY_BUFFERED
      Throws:
      JspException - if an error occurred while processing this tag
      See Also:
    • getDefault

      public String getDefault()
      Returns:
      the default value
    • getMode

      public String getMode()
      Returns:
      the mode
    • getValue

      public String getValue()
      Returns:
      the value
    • setDefault

      public void setDefault(String defaultValue)
      Parameters:
      defaultValue - the default value to set
    • setMode

      public void setMode(String mode)
      Parameters:
      mode - the mode to set
    • setValue

      public void setValue(String value)
      Parameters:
      value - the value to set