Be careful about upgrade if you use | etc. in the URL of Tomcat

From Tomcat 8.0.39, 8.5.7, 7.0.73, it is a specification that throws an error if the URL contains | etc. Be careful if you are involved in maintaining legacy applications.

java.lang.IllegalArgumentException: Invalid character found in the request target. The valid characters are defined in RFC 7230 and RFC 3986
	at org.apache.coyote.http11.InternalInputBuffer.parseRequestLine(InternalInputBuffer.java:189)
	at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1000)
	at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:637)
	at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:316)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
	at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
	at java.lang.Thread.run(Thread.java:745)

Relation: http://stackoverflow.com/questions/41053653/tomcat-8-is-not-able-to-handle-get-request-with-in-query-parameters

Test check repository https://github.com/takeo-asai/tomcat-invalid-character

Recommended Posts

Be careful about upgrade if you use | etc. in the URL of Tomcat
Be careful if you find SHIFT-JIS in Java
If you use Spring's DataSourceTransactionManager, it may be committed in case of error! ??
[Rails] Where to be careful in the description of validation
(Determine in 1 minute) About the proper use of empty ?, blank? And present?
If you want to satisfy the test coverage of private methods in JUnit
About the meaning of type variables, E, T, etc. used in generics used in Java
Be absolutely careful when putting the result of and / or in a variable!
About the idea of anonymous classes in Java
With Tomcat you can use placeholders ($ {...}) in web.xml
[Java] Be careful of the key type of Map
What to do if you can't get the text of an element in Selenium
If you make a mistake in the description location of Gem, delete Gemfile.lock once.
Get the URL of the HTTP redirect destination in Java
Format of the log output by Tomcat itself in Tomcat 8
Prepare the execution environment of Tomcat in IntelliJ Community
Access the war file in the root directory of Tomcat
Set the root URL when starting tomcat in intelliJ
If you want to recreate the instance in cloud9
Get the URL of the HTTP redirect destination in Ruby
Even if I write the setting of STRICT_QUOTE_ESCAPING in CATALINA_OPTS in tomcat8.5, it is not reflected.
What to do if you get further occurrences of http header parsing errors will be logged at debug level. In tomcat 8.5.37
Solution if you delete the migration file in the up state
Have you ever thought about the definition of "bad design"?
What to do if you can't use the rails command
[Swift] When you want to know if the number of characters in a String matches a certain number ...
If you want to mock a method in RSpec, you should use the allow method for mock and the singleton method.
[Be careful about changing the version of Xdebug! ] Create a development environment with Xdebug3 + docker + VS Code