VYPR
Critical severityNVD Advisory· Published Dec 26, 2021· Updated Aug 4, 2024

CVE-2021-45701

CVE-2021-45701

Description

An issue was discovered in the tremor-script crate before 0.11.6 for Rust. A patch operation may result in a use-after-free.

AI Insight

LLM-synthesized narrative grounded in this CVE's description and references.

The tremor-script crate before 0.11.6 has a use-after-free when using patch or merge on state and assigning the result back to state.

Vulnerability

The tremor-script crate before version 0.11.6 contains a use-after-free vulnerability when using patch or merge operations on state and assigning the result back to state. Specifically, constructs like let state = merge state of event end; or let state = patch state of insert event.key => event.value end; trigger an in-place optimization that manipulates the target value without cloning it. This optimization is safe only when operating on event data or static data, but with the introduction of state (which persists across events), it can lead to memory unsafety [1][3].

Exploitation

An attacker who can control the event data in a tremor-script pipeline can trigger the vulnerable code path. No special authentication or network position beyond normal pipeline operation is required. By crafting specific event data that causes the patch or merge to reference event fields within the assignment-back pattern, the attacker can cause the Value structure to maintain references to memory that has been freed, leading to a use-after-free [1][3].

Impact

Successful exploitation results in memory corruption and potential memory exposure. The attacker may be able to read freed memory or cause undefined behavior, potentially leading to information disclosure or denial of service. The vulnerability affects the tremor-script crate, which is used in the Tremor runtime (tremor-rs/tremor-runtime). The CVSS score is yet to be disclosed, but the advisory categorizes it under memory corruption and memory exposure [1][2][3].

Mitigation

The vulnerability is fixed in version 0.11.6 of the tremor-script crate. The fix involves removing the in-place optimization for patch and merge operations, as described in pull request #1217 on the tremor-rs/tremor-runtime repository [1][4]. Versions earlier than 0.7.2 are unaffected because they did not include the vulnerable optimization [1][3]. Users should upgrade to 0.11.6 or later to mitigate the issue.

AI Insight generated on May 21, 2026. Synthesized from this CVE's description and the cited reference URLs; citations are validated against the source bundle.

Affected packages

Versions sourced from the GitHub Security Advisory.

PackageAffected versionsPatched versions
tremor-scriptcrates.io
>= 0.7.2, < 0.11.60.11.6

Affected products

2

Patches

0

No patches discovered yet.

Vulnerability mechanics

AI mechanics synthesis has not run for this CVE yet.

References

5

News mentions

0

No linked articles in our index yet.