eBay CORS filter is a Java Servlet Filter implementation of server-side CORS for Java web containers such as Apache Tomcat. Salient features:
- Easy to integrate and use – enable CORS capability with a few lines in your web.xml!
- Protects against CRLF injection / response splitting attacks.
Another CORS filter for Java is is also available here.