Skip to content

KAFKA-20815: Remove unnecessary jline deps and bump to latest 3.x#22898

Merged
mimaison merged 3 commits into
apache:trunkfrom
harmadasg:remove-unnecessary-jline-deps
Jul 22, 2026
Merged

KAFKA-20815: Remove unnecessary jline deps and bump to latest 3.x#22898
mimaison merged 3 commits into
apache:trunkfrom
harmadasg:remove-unnecessary-jline-deps

Conversation

@harmadasg

@harmadasg harmadasg commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

KAFKA-20815 reported a security vulnerability on jline-remote-telnet
3.30.4. Kafka does not have a dependency on the mentioned package but
actually uses the whole jline bundle which includes telnet related
binaries too. Jline is only used for the metadata shell module which in
turn only needs it for basic terminal functionality, there are no remote
capabilities. This PR aims to remove the unnecessary jline dependencies
and prevent false positive security vulnerability scan results about
jline telnet/ssh.

The shell module only needs the jline-reader dependency which also
pulls in transitive dependencies jline-terminal and jline -native.

As an additional benefit the change reduces binary size going from jline
bunde (1.40 MB) to jline-reader + jline-terminal + jline-native (650 KB)
~ 55% saved

While at it the dependency version has been updated to the latest 3.x
release

Reviewers: Mickael Maison mickael.maison@gmail.com

@github-actions github-actions Bot added triage PRs from the community dependencies Pull requests that update a dependency file build Gradle build or GitHub Actions small Small PRs labels Jul 21, 2026
Comment thread LICENSE-binary Outdated
BSD 3-Clause

- jline-3.30.4, see: licenses/jline-BSD-3-clause
- jline-3.30.15, see: licenses/jline-BSD-3-clause

@mimaison mimaison Jul 21, 2026

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This must contain the names of the JARs we ship. So we need:

  • jline-native-3.30.15
  • jline-reader-3.30.15
  • jline-terminal-3.30.15

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks I fixed it in 1398ee4 and also verified it with the committer-tools/verify_license.py script

@github-actions github-actions Bot removed the triage PRs from the community label Jul 22, 2026

@mimaison mimaison left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@mimaison
mimaison merged commit df0392f into apache:trunk Jul 22, 2026
23 checks passed
jersey: "3.1.10",
jgit: "7.6.0.202603022253-r",
jline: "3.30.4",
jline: "3.30.15",

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

3.30.16 was just released, and we just missed the bus 😆

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so close 😄

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@harmadasg do you have time to file a patch so we can catch the next bus?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sure I can do it

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@chia7712 I have opened #22906, no danger of missing the bus this time 😄

mimaison pushed a commit that referenced this pull request Jul 22, 2026
See [KAFKA-20815](https://issues.apache.org/jira/browse/KAFKA-20815) and
#22898 (comment)

Reviewers: Ken Huang <s7133700@gmail.com>, Mickael Maison
 <mickael.maison@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

build Gradle build or GitHub Actions ci-approved dependencies Pull requests that update a dependency file small Small PRs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants