Track vulnerabilities like this one. Sign up free to get alerted when software you use is affected.
7.5

CVE-2026-77422: JLine built-in grep can hang console

CVE-2026-77422 · published 1 month ago
Summary

The JLine library used for Java console input lets its built‑in grep command add extra characters to any search pattern you provide. This can cause the command to consume a lot of CPU and stop responding, especially when accessed over a remote shell. Upgrade to the latest JLine versions that include the fix.

What to do
  • Update jline org.jline:jline-builtins to version 4.3.1.
  • Update jline org.jline:jline-builtins to version 3.30.15.
  • Update org.jline:jline-builtins to version 4.3.1.
  • Update org.jline:jline-builtins to version 3.30.15.
  • Update org.jline:jline-builtins to version 3.25.1-aikido.4.
  • Update io.root.org.jline:jline-builtins to version 3.25.1-root.io.4.
Affected software
Ecosystem VendorProductAffected versions
maven jline org.jline:jline-builtins >= 4.0.0, < 4.3.1
>= 3.0.0, < 3.30.15
Fix: upgrade to 4.3.1
maven – org.jline:jline-builtins >= 4.0.0, < 4.3.1
>= 3.0.0, < 3.30.15
Fix: upgrade to 4.3.1
– jline jline3 >= 3.0.0, < 3.30.15
Ubuntu:14.04:LTS canonical jline All versions
Ubuntu:14.04:LTS canonical jline2 All versions
Ubuntu:22.04:LTS canonical jline3 All versions
Debian:12 debian jline3 All versions
Root:Maven – org.jline:jline-builtins < 3.25.1-aikido.4
Fix: upgrade to 3.25.1-aikido.4
Root:Maven – io.root.org.jline:jline-builtins < 3.25.1-root.io.4
Fix: upgrade to 3.25.1-root.io.4
Original advisory text
JLine: ReDoS in Built-in grep Command Amplified by Automatic `.*` Wrapping
JLine is a Java library for handling console input. From 3.0.0 until 3.30.15 and 4.3.1, the JLine built-in grep command in builtins/src/main/java/org/jline/builtins/PosixCommands.java accepts a user-controlled regular expression in grep(...) and, unless line-regexp mode is used, automatically adds a dot-star prefix and suffix before compiling it with Java's backtracking regular expression engine. The wrapping expands the backtracking search space, so a short nested-quantifier expression evaluated against non-matching input can consume excessive CPU and indefinitely block a command worker, including in remotely exposed shell sessions. This issue is fixed in versions 3.30.15 and 4.3.1.
Fix within
Internet-facing 14 days
Internal 60 days
  • Not known to be exploited
  • Can be exploited automatically
  • Gives an attacker partial control
Severity
7.5 High
Exploitation
<1% chance of attack within 30 days
Type
CWE-1333Inefficient Regular Expression Complexity (ReDoS)
Timeline
Published23 Sep 2026
Updated4 Nov 2026
First seen23 Sep 2026
Track software like this
Free during beta