markt-asf commented on a change in pull request #417: URL: https://github.com/apache/tomcat/pull/417#discussion_r622818008
########## File path: java/org/apache/coyote/http11/Http11InputBuffer.java ########## @@ -550,10 +550,15 @@ boolean parseRequestLine(boolean keptAlive, int connectionTimeout, int keepAlive prevChr = chr; chr = byteBuffer.get(); if (chr == Constants.CR) { - // Possible end of request line. Need LF next. + // Possible end of request line. Need LF next else invalid. } else if (prevChr == Constants.CR && chr == Constants.LF) { + // CRLF is the standard line terminator end = pos - 1; parsingRequestLineEol = true; + } else if (chr == Constants.LF) { Review comment: It would make the code a little more complex and there is nothing in the spec to suggest that self-consistency is required. If we were going to make the behaviour configurable I can see how this would fit into an option that allow varying degrees of LF use. Eg: none, consistent, any. My current thinking is to essentially hard-code the any option unless someone identifies a good reason not to. -- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org