# CVE-2026-46718: Apache Calcite unsafe reflection in user-controlled models

Source: https://junglewise.ai/threats/cve-2026-46718-apache-calcite-unsafe-reflection-in-user-controlled-models  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-06-02. Updated: 2026-07-09  
License: CC BY 4.0 with a link back

CVE-2026-46718 · Severity: medium · CVSS 6.5 · Published 2026-06-02

Apache Calcite, a framework used by many database systems to manage and optimize data queries, contains a security flaw in how it handles user-provided data models. An attacker can provide a specially crafted model that forces the software to load unauthorized Java classes. This could allow an attacker to execute malicious code on the server or gain unauthorized access to sensitive data.

Technologies: [org.apache.calcite:calcite-core (Maven)](https://junglewise.ai/threats/technologies/org-apache-calcite-calcite-core). Vendors: [Apache Software Foundation](https://junglewise.ai/threats/vendors/apache-software-foundation), [Maven](https://junglewise.ai/threats/vendors/maven).

## Quick answers

**Is CVE-2026-46718 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2026-46718 being exploited in the wild.

**How severe is CVE-2026-46718?** Medium severity, with a CVSS score of 6.5, published 2 June 2026.

**Which products and versions are affected?** Apache Software Foundation Calcite 1.5.0 to 1.41.0; org.apache.calcite:calcite-core (Maven) >= 1.5.0, < 1.42.0, ECOSYSTEM:introduced=1.5.0,fixed=1.42.0.

**Is there a fix for CVE-2026-46718?** Yes. org.apache.calcite:calcite-core (Maven): upgrade to 1.42.0 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2026-46718 attacked?** It is attacked over the network, in a software library.

**Am I affected by CVE-2026-46718?** Check whether you run Apache Software Foundation Calcite or org.apache.calcite:calcite-core (Maven) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- org.apache.calcite:calcite-core (Maven): upgrade to 1.42.0 or later

  ```sh
  # set org.apache.calcite:calcite-core to 1.42.0 in your pom.xml or build.gradle
  ```


## Technical details

Apache Calcite is vulnerable to 'Unsafe Reflection' (CWE-470) within its model parsing component (calcite-core). The vulnerability exists because the framework uses externally-controlled input from a schema model to select and load Java classes (such as user-defined functions, JDBC drivers, or custom schemas) without sufficient validation or denylisting. An attacker who can provide a malicious model—for example, via a JDBC connection string or an inline model parser—can trigger the loading of arbitrary classes. This can be leveraged to achieve remote code execution (RCE) or unauthorized data access. The fix, introduced in version 1.42.0, implements a built-in denylist of restricted class patterns and provides a system property to extend this list.

## Affected products

- Apache Calcite 1.5.0 to 1.41.0

## Identifiers

- CVE-2026-46718
- GHSA-c2rv-hwqm-wjpg

## Timeline

- 2026-05-16: other: Initial fix development started
- 2026-06-01: disclosed: Public disclosure on oss-security mailing list
- 2026-06-02: advisory: GitHub and NVD advisories published
- 2026-07-09: patched: GitHub advisory reviewed and updated with patch details

## References

- [https://lists.apache.org/thread/9s37svo343w5ck1ovh478lkzcqk4949v](https://lists.apache.org/thread/9s37svo343w5ck1ovh478lkzcqk4949v)
- [http://www.openwall.com/lists/oss-security/2026/06/01/7](http://www.openwall.com/lists/oss-security/2026/06/01/7)
- [https://github.com/apache/calcite/commit/5855cfa14d8038e2a123ff6ce9722edce0e0cc25](https://github.com/apache/calcite/commit/5855cfa14d8038e2a123ff6ce9722edce0e0cc25)
- [https://issues.apache.org/jira/browse/CALCITE-7532](https://issues.apache.org/jira/browse/CALCITE-7532)

## Related threats

- [Apache Calcite before 1.32.0 vulnerable to potential XML External Entity (XXE) attack](https://junglewise.ai/threats/cve-2022-39135-apache-calcite-before-1-32-0-vulnerable-to-potential-xml-external)
- [Missing Authentication for Critical Function in Apache Calcite](https://junglewise.ai/threats/cve-2020-13955-missing-authentication-for-critical-function-in-apache-calcite)
