XSS filter ver. 1.1

This is a Java servlet filter (as per Servlet API 2.3). This filter lets you deal with Cross Site Scripting (XSS) attempts. Filter intercepts every request sent to your web application and then cleans any potential script injection.

How to use it:

a) download xssflt.jar and save it in WEB-INF/lib

b) describe this filter in web.xml.
 


<filter>
  <filter-name>XSSFilter</filter-name>
  <filter-class>com.cj.xss.XSSFilter</filter-class>
</filter>

d) describe a mapping for this filter in web.xml. E.g.:
 


<filter-mapping>
  <filter-name>XSSFilter</filter-name>
  <url-pattern>/*</url-pattern>
</filter-mapping>

in this example filter will be on for the each file.

   For downloading:

    XSS package:  xssflt.jar
 

 ©  Coldbeans     Comments?

See also JSOS - the largest collection of servlets and filters.

Also in JSOS: