https://bz.apache.org/bugzilla/show_bug.cgi?id=69918
Bug ID: 69918
Summary: Case where
org.apache.catalina.connector.Request.getParameter(Str
ing s) doesn't parse parameters
Product: Tomcat 9
Version: unspecified
Hardware: Macintosh
Status: NEW
Severity: normal
Priority: P2
Component: Catalina
Assignee: [email protected]
Reporter: [email protected]
Target Milestone: -----
To Reproduce:
setup -
Tomcat 9.0.107, using HTTP/2, the `content-length` header is
not being set, the `content-type` header is set to
`application/x-www-form-urlencoded`, and the HTTP method is `POST`.
With that setup, when the server receives an http request with query
parameters,
org.apache.catalina.connector.Request.getParameter("some_parameter")
no longer results in the parameters getting parsed in the
request.parseParameters() method.
I think what happens is in
https://github.com/apache/tomcat/blob/9.0.x/java/org/apache/catalina/connector/Request.java#L3094
the `len` variable is set to -1, and we fall out in the `if` statement
below it.
Mark Thomas said on the users mailing list
"The fix is probably changing "...else if chunked..." to "...else if
chunked or HTTP/2..." "
--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]