File tree Expand file tree Collapse file tree 2 files changed +6
-1
lines changed
java/org/apache/coyote/http11 Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -381,7 +381,7 @@ boolean parseRequestLine(boolean keptAlive) throws IOException {
381381 // Switch to the socket timeout.
382382 wrapper .setReadTimeout (wrapper .getEndpoint ().getConnectionTimeout ());
383383 }
384- if (!keptAlive && byteBuffer .position () == 0 && byteBuffer .limit () >= CLIENT_PREFACE_START .length - 1 ) {
384+ if (!keptAlive && byteBuffer .position () == 0 && byteBuffer .limit () >= CLIENT_PREFACE_START .length ) {
385385 boolean prefaceMatch = true ;
386386 for (int i = 0 ; i < CLIENT_PREFACE_START .length && prefaceMatch ; i ++) {
387387 if (CLIENT_PREFACE_START [i ] != byteBuffer .get (i )) {
Original file line number Diff line number Diff line change 172172 the maximum value to 255. Based on a PR <pr >548</pr > by Stefan Mayr.
173173 (lihan)
174174 </fix >
175+ <fix >
176+ <pr >551</pr >: Avoid potential IndexOutOfBoundsException by fixing
177+ incorrect check when matching HTTP/2 preface. Submitted by 刘文章.
178+ (lihan)
179+ </fix >
175180 </changelog >
176181 </subsection >
177182 <subsection name =" Jasper" >
You can’t perform that action at this time.
0 commit comments