rootvector2 opened a new pull request, #1550: URL: https://github.com/apache/httpcomponents-core/pull/1550
`DefaultH2RequestConverter#convert` accepts any `:method`, `:scheme` or `:path` that passes the generic field-value check, so `:method: GET /admin HTTP/1.1` reaches the handler and is re-serialized by `BasicLineFormatter` as `GET /admin HTTP/1.1 /public HTTP/1.1` on an HTTP/1.1 downgrade (request-line injection, which the HTTP/1.1 front end cannot produce because `BasicLineParser` splits on whitespace); found by reading the converter against RFC 9113 section 8.3.1 and reproduced with the converter and formatter, so validate `:method` as an RFC 9110 token, `:scheme` against the RFC 3986 scheme grammar and reject whitespace in `:path` in the converter, failing the stream with `PROTOCOL_ERROR` per section 8.1.1, with regression tests. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
