CVE-2021-28035
Rust vulnerability analysis and mitigation

Overview

An issue was discovered in the stack_dst crate before version 0.6.1 for Rust, identified as CVE-2021-28035. The vulnerability stems from the push_inner behavior, where a drop of uninitialized memory can occur upon a val.clone() panic (RUSTSEC Advisory, NVD).

Technical details

The vulnerability is related to the push_inner function implementation in the stack_dst crate. When the function increases the internal length of the array and then calls val.clone(), a panic during the clone operation can lead to memory corruption. The issue has been assigned a CVSS v3.1 base score of 9.8 (CRITICAL) with the vector CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H. The weakness has been classified as CWE-908 (Use of Uninitialized Resource) (RUSTSEC Advisory, NVD).

Impact

The vulnerability can result in two severe consequences: the dropping of uninitialized memory or a double free condition when a panic occurs during the clone operation. This can lead to memory corruption and potential security implications in applications using the affected versions of the stack_dst crate (RUSTSEC Advisory).

Exploitability

The vulnerability affects the stack_dst::StackA::push_cloned function in versions prior to 0.6.1. The issue occurs specifically when the val.clone() operation panics during execution (RUSTSEC Advisory).

Mitigation and workarounds

The vulnerability has been fixed in version 0.6.1 of the stack_dst crate. The fix involves modifying the push_inner function to increase the length of the array after elements are cloned, rather than before. Users should upgrade to version 0.6.1 or later to address this security issue (RUSTSEC Advisory).

Additional resources


SourceThis report was generated using AI

Related Rust vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

GHSA-m3wp-48jr-vr4gHIGH7.5
  • Rust logoRust
  • mistralrs-server-core
NoYesSep 10, 2026
GHSA-wfgq-w7cq-qj7jHIGH7.2
  • Rust logoRust
  • mistralrs-server-core
NoYesSep 10, 2026
CVE-2026-45056MEDIUM6.9
  • Rust logoRust
  • matrix-sdk-crypto
NoYesSep 11, 2026
CVE-2026-53956MEDIUM5.4
  • Python logoPython
  • rattler_cache
NoYesSep 09, 2026
CVE-2026-45057MEDIUM4.9
  • Rust logoRust
  • matrix-sdk-ui
NoYesSep 11, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management