Vulnerabilities in pkg:maven/com.cronutils/cron-utils
PACKAGECVE-2021-41269 is a CRITICAL (CVSS 10.0) critical vulnerability found vulnerability (CWE-94: Improper Control of Generation of Code ('Code Injection')) affecting Cron utils libraries in the Maven ecosystem. The issue involves critical vulnerability found in cron-utils. Remediation is available by upgrading affected packages to version 9.1.6.
pkg:maven/com.cronutils/cron-utils
Vulnerability advisories affecting package pkg:maven/com.cronutils/cron-utils. Select an advisory below to view technical details or fixes.
| Advisory ID | CVE / NVD | Severity | Summary |
|---|---|---|---|
| GHSA-p9m8-27x8-rg87 | CVE-2021-41269 | CRITICAL | Critical vulnerability found in cron-utils |
| GHSA-pfj3-56hm-jwq5 | CVE-2020-26238 | CRITICAL | Template injection in cron-utils |
CVE-2021-41269 at a Glance
Security Impact
CVSS: 10.0
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H).
How to Fix CVE-2021-41269
To remediate this vulnerability, upgrade all affected Cron utils dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
<dependency>
<groupId>com.cronutils</groupId>
<artifactId>cron-utils</artifactId>
<version>9.1.6</version>
</dependency>
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
mvn dependency:tree -Dincludes=com.cronutils
How to Check if You Are Affected
To determine whether your Java application is affected by CVE-2021-41269, inspect your build dependencies using the Maven Dependency Plugin:
mvn dependency:tree -Dincludes=com.cronutils
Analyze the terminal output to locate any version of Cron utils in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 9.1.6), your application is affected.
Note: The mvn dependency:tree -Dincludes=com.cronutils command inspects the resolved dependency graph declared in your project's POM files; it does not perform automated security scanning or inspect runtime dynamic classpaths. Always verify runtime container classpaths and shaded JARs.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-94: Improper Control of Generation of Code ('Code Injection'), where the product constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the syntax or behavior of the intended code segment. In Cron utils, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2021-41269 Affected Cron utils Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
com.cronutils:cron-utils
|
Maven |
< 9.1.6
|
9.1.6
|
References
Frequently Asked Questions
What is CVE-2021-41269?
Which Cron utils versions are affected?
What version fixes CVE-2021-41269?
Is cron-utils affected?
What is the CVSS score of CVE-2021-41269?
What CWE is associated with CVE-2021-41269?
How can I check Maven dependencies for CVE-2021-41269?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-p9m8-27x8-rg87",
"modified" : "2021-11-15T22:23:17Z",
"published" : "2021-11-15T23:27:11Z",
"aliases" : [ "CVE-2021-41269" ],
"summary" : "Critical vulnerability found in cron-utils",
"details" : "### Impact\nA Template Injection was identified in cron-utils enabling attackers to inject arbitrary Java EL expressions, leading to unauthenticated Remote Code Execution (RCE) vulnerability. Versions up to 9.1.2 are susceptible to this vulnerability. Please note, that only projects using the @Cron annotation to validate untrusted Cron expressions are affected.\n\n### Patches\nThe issue was patched and a new version was released. Please upgrade to version 9.1.6.\n\n### Workarounds\nThere are no known workarounds up to this moment.\n\n### References\nA description of the issue is provided in [issue 461](https://github.com/jmrozanec/cron-utils/issues/461)\n\n### For more information\nIf you have any questions or comments about this advisory:\n\nOpen an issue in the [cron-utils Github repository](https://github.com/jmrozanec/cron-utils)",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Maven",
"name" : "com.cronutils:cron-utils"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "9.1.6"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/jmrozanec/cron-utils/security/advisories/GHSA-p9m8-27x8-rg87"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2021-41269"
}, {
"type" : "WEB",
"url" : "https://github.com/jmrozanec/cron-utils/issues/461"
}, {
"type" : "WEB",
"url" : "https://github.com/jmrozanec/cron-utils/commit/cfd2880f80e62ea74b92fa83474c2aabdb9899da"
}, {
"type" : "WEB",
"url" : "https://github.com/jmrozanec/cron-utils/commit/d6707503ec2f20947f79e38f861dba93b39df9da"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/jmrozanec/cron-utils"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-94" ],
"severity" : "CRITICAL",
"github_reviewed" : true,
"github_reviewed_at" : "2021-11-15T22:23:17Z",
"nvd_published_at" : "2021-11-15T21:15:00Z"
}
}