WaratekVRT Sign in

CVE-2022-24881 Ballcat Codegen

Affected softwareBallcat Codegen
Severity9.8 Critical CVSS 3.1 3 scores
Fixed in1.0.0.beta.2
WeaknessCode injection (CWE-94)
Published26 Apr 2022
Updated17 Jun 2026

Description

Ballcat Codegen provides the function of online editing code to generate templates. In versions prior to 1.0.0.beta.2, attackers can implement remote code execution through malicious code injection of the template engine. This happens because Velocity and freemarker templates are introduced but input verification is not done. The fault is rectified in version 1.0.0.beta.2.

CWE-20 · Improper input validationCWE-78 · OS command injection

Exploitation status

Proof of concept only

A proof of concept exists, but no reviewed exploit catalogue lists this CVE.

  • CISA KEV not listed
  • VulnCheck KEV not listed
  • CISA Vulnrichment exploitation: poc CISA recorded that an exploit has been demonstrated. Automatable: no, technical impact: total.
  • Indexed PoC none indexed
  • EPSS 3.2% chance in 30 days

Waratek protection

Protected by Waratek

Waratek has a rule that blocks attacks on this vulnerability.

Decided by A vulnerability class already blocked by an ARMR security rule
Finding Protected by Waratek's ARMR command-injection security rule, which blocks this class of attack at the JVM level without a rule written for this CVE specifically. The CVE's weakness is CWE-78: OS Command Injection.
Candidate fix https://github.com/ballcat-projects/ballcat-codegen/commit/84a7cb38daf0295b93aba21d562ec627e4eb463b : a commit: the change itself

How to mitigate CVE-2022-24881

Upgrade Ballcat Codegen to 1.0.0.beta.2 or later. Until you can, Waratek RASP blocks exploitation with its process rule. It runs inside the Java application, with no code changes.

Waratek RASP Runtime protection for Java applications

CVSS

9.8 CRITICAL v3.1 CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H 3 metrics

We show the highest score from the newest CVSS version. Scores from different versions can't be compared, and the first score listed is sometimes a 0.0 placeholder.

VersionScoreBandVectorAssignerType
CVSS 3.1 9.8 CRITICAL CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H NVD Primary published
CVSS 3.1 8.8 HIGH CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H security-advisories@github.com Secondary
CVSS 2.0 7.5 none AV:N/AC:L/Au:N/C:P/I:P/A:P NVD Primary

Affected software and releases

Maven packages

Affected and fixed versions, from OSV.dev
PackageIntroducedFixedLast affected
com.hccake:ballcat-codegen 0 1.0.0.beta.2 unbounded

Products and versions

2 products, 2 version entries
SourceVendorProductSchemeAffected versions
nvd ballcat codegen generic < 1.0.0
osv com.hccake ballcat-codegen generic < 1.0.0

References

URLTags
https://github.com/ballcat-projects/ballcat-codegen/commit/84a7cb38daf0295b93aba21d562ec627e4eb463b commit
https://github.com/ballcat-projects/ballcat-codegen/security/advisories/GHSA-fv3m-xhqw-9m79 WEB
https://github.com/ballcat-projects/ballcat-codegen/issues/5 WEB
https://github.com/ballcat-projects/ballcat-codegen PACKAGE

Timeline

Published2022-04-26By the CVE Program.
NVD record modified2026-06-17NVD's own last-modified date for this record.