Skip to content

Commit b422fdf

Browse files
authored
Merge pull request #1555 from fl4via/UNDERTOW-2280
[UNDERTOW-2280] CVE-2023-5379 At AjpReadListener, do not close the co…
2 parents 93d1549 + b073261 commit b422fdf

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

core/src/main/java/io/undertow/server/protocol/ajp/AjpReadListener.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
package io.undertow.server.protocol.ajp;
2020

2121
import io.undertow.UndertowLogger;
22+
import io.undertow.UndertowMessages;
2223
import io.undertow.UndertowOptions;
2324
import io.undertow.conduits.ConduitListener;
2425
import io.undertow.conduits.EmptyStreamSourceConduit;
@@ -165,8 +166,7 @@ public void handleEvent(final StreamSourceChannel channel) {
165166
}
166167
if (read > maxRequestSize) {
167168
UndertowLogger.REQUEST_LOGGER.requestHeaderWasTooLarge(connection.getPeerAddress(), maxRequestSize);
168-
safeClose(connection);
169-
return;
169+
throw UndertowMessages.MESSAGES.badRequest();
170170
}
171171
} while (!state.isComplete());
172172

0 commit comments

Comments
 (0)