On Mon, 20 Apr 2026 18:01:08 GMT, Chris Plummer <[email protected]> wrote:
> If an invalid JDWP command set number or command number is sent to the debug > agent, it can result in branching to an unknown location, usually resulting > in a crash. See first comment for details. > > Tested with CI tier1, tier2 svc, and tier5 svc. > > --------- > - [x] I confirm that I make this contribution in accordance with the [OpenJDK > Interim AI Policy](https://openjdk.org/legal/ai). src/jdk.jdwp.agent/share/native/libjdwp/debugDispatch.c line 101: > 99: *cmdName_p = "<Unknown Command>"; > 100: > 101: if (cmdSetNum < 0 || cmdSetNum > JDWP_HIGHEST_COMMAND_SET) { Q: I wonder why the check for command set number is not: `cmdSetNum < 1` as for the command number below at line 111? ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/30827#discussion_r3115807450
