RequestUtil (Apache Tomcat 8.5.12 API Documentation)

org.apache.catalina.util

## Class RequestUtil

- java.lang.Object
- - org.apache.catalina.util.RequestUtil

-     public final class RequestUtil
      extends Object

  General purpose request parsing and encoding utility methods.
  Author:
    Craig R. McClanahan, Tim Tye

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `RequestUtil()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static String` | `filter(String message)` Filter the specified message string for characters that are sensitive in HTML.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### RequestUtil

          public RequestUtil()

  - ### Method Detail

    - #### filter

          public static String filter(String message)

      Filter the specified message string for characters that are sensitive in HTML. This avoids potential attacks caused by including JavaScript codes in the request URL that is often reported in error messages.
      Parameters:
        `message` - The message string to be filtered
      Returns:
        the filtered message

Copyright © 2000-2017 Apache Software Foundation. All Rights Reserved.