Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Strict Quote Escaping in Tomcat

This is regarding strict quote escaping in tomcat mentioned in http://blogs.sourceallies.com/2009/10/strict-quote-escaping-in-tomcat/

I am using apache-tomcat-6.0.36 and I am not facing any issue related to this. So is this issue specific only to certain versions of tomcat 6+? Also does this depend on J2EE version?

Note : I haven't configured org.apache.jasper.compiler.Parser.STRICT_QUOTE_ESCAPING in $TOMCAT_HOME/conf/catalina.properties

like image 852
thiru_k Avatar asked Sep 17 '25 12:09

thiru_k


1 Answers

Tomcat8 has deprecated and removed previous property which may break installations if older instructions are to be followed. See this guide to fix issue.

Tomcat7 and earlier versions

Add this property to the end of $tomcat/conf/catalina.properties file.

org.apache.jasper.compiler.Parser.STRICT_QUOTE_ESCAPING=false

Tomcat8 and most recent versions

Add this parameter to the JspServlet in $tomcat/conf/web.xml file.

Find this servlet <servlet-class>org.apache.jasper.servlet.JspServlet</servlet-class>

Add parameter <init-param><param-name>strictQuoteEscaping</param-name><param-value>false</param-value></init-param>

like image 126
Whome Avatar answered Sep 20 '25 03:09

Whome