问题分析
出现这种问题,是因为各版本tomcat中对特殊字符和请求路径中携带中文参数而产生的错误提示
解决办法
1.调整tomcat版本
tomcat 7.0.76之前的版本不会出现类似问题
2.tomcat9之前,修改tomcat目录底下的/conf/catalina.properties
#tomcat.util.http.parser.HttpParser.requestTargetAllow=|
3.tomcat9之后,修改tomcat目录底下的/conf/server.xml
<Connector executor="tomcatThreadPool"
port="80" protocol="HTTP/1.1"
connectionTimeout="20000"
redirectPort="443" relaxedPathChars="|{}[],%" relaxedQueryChars="|{}[],%"/>