
Cloud Vulnerability DB
A community-led vulnerabilities database
cassandra-rs, a Cassandra (CQL) driver for Rust, contains a use-after-free vulnerability in versions prior to 3.0.0. The vulnerability was discovered on February 28, 2024, and affects code that attempts to use an item (e.g., a row) returned by an iterator after the iterator has advanced to the next item (GitHub Advisory).
The vulnerability stems from a non-idiomatic use of iterators where accessing an item after calling next() on the iterator results in accessing freed memory. The issue occurs because the underlying Cassandra driver invalidates the current item when next() is called, which was not properly reflected in the Rust binding prior to version 3.0.0. The vulnerability has been assigned CVE-2024-27284 and is classified as CWE-416 (Use After Free). The CVSS v3.1 score is 7.5 (High) with vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H (GitHub Advisory).
When exploited, this vulnerability leads to undefined behavior due to accessing freed memory. While the severity is rated as high due to being a use-after-free bug, it typically results in immediate program failure, making it unlikely that vulnerable code would have reached production environments. The impact primarily affects applications that use items returned by a cassandra-rs iterator after calling next() on that iterator (GitHub Advisory).
The vulnerability is triggered when code attempts to use an item returned by an iterator after the iterator has advanced to the next item. However, such code patterns typically fail immediately, making successful exploitation unlikely in production environments. The vulnerability requires no special privileges or user interaction to exploit (GitHub Advisory).
The vulnerability has been fixed in version 3.0.0 of cassandra-rs. Users are strongly recommended to upgrade to this version. For those unable to upgrade immediately, workarounds include using get_first_row() rather than an iterator, or ensuring all processing of an item is completed before advancing the iterator with next(). The fix involves implementing a new LendingIterator trait instead of the standard Iterator trait (GitHub Advisory).
Source: This report was generated using AI
Free Vulnerability Assessment
Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.
Get a personalized demo
"Best User Experience I have ever seen, provides full visibility to cloud workloads."
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
"We know that if Wiz identifies something as critical, it actually is."