# CVE-2018-20991: RUSTSEC-2018-0003 - Possible double free during unwinding in SmallVec::insert_many

Source: https://junglewise.ai/threats/cve-2018-20991-double-free-in-smallvec  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2018-07-19  
License: CC BY 4.0 with a link back

CVE-2018-20991 · Severity: low · CVSS 3 · Published 2018-07-19

Possible double free during unwinding in SmallVec::insert_many

Technologies: [smallvec (crates.io)](https://junglewise.ai/threats/technologies/smallvec). Vendors: [crates.io](https://junglewise.ai/threats/vendors/crates-io).

## Quick answers

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

**How severe is CVE-2018-20991?** Low severity, with a CVSS score of 3, published 19 July 2018.

**Which products and versions are affected?** smallvec (crates.io) SEMVER:introduced=0.3.2,fixed=0.3.4,introduced=0.4.0-0,fixed=0.4.5,introduced=0.5.0-0,fixed=0.5.1,introduced=0.6.0-0,fixed=0.6.3, SEMVER:introduced=0.3.2,fixed=0.6.3.

**Is there a fix for CVE-2018-20991?** Yes. smallvec (crates.io): upgrade to 0.6.3 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**Am I affected by CVE-2018-20991?** Check whether you run smallvec (crates.io) 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

- smallvec (crates.io): upgrade to 0.6.3 or later

  ```sh
  cargo update -p smallvec
  ```


## Affected products

- smallvec (crates.io) SEMVER:introduced=0.3.2,fixed=0.3.4,introduced=0.4.0-0,fixed=0.4.5,introduced=0.5.0-0,fixed=0.5.1,introduced=0.6.0-0,fixed=0.6.3, SEMVER:introduced=0.3.2,fixed=0.6.3

## Identifiers

- CVE-2018-20991
- GHSA-rxr4-x558-x7hw
- RUSTSEC-2018-0003

## Related threats

- [RUSTSEC-2021-0003 - Buffer overflow in SmallVec::insert_many](https://junglewise.ai/threats/cve-2021-25900-buffer-overflow-in-smallvec-insert-many)
- [RUSTSEC-2019-0012 - Memory corruption in SmallVec::grow()](https://junglewise.ai/threats/cve-2019-15554-memory-corruption-in-smallvec)
- [RUSTSEC-2019-0009 - Double-free and use-after-free in SmallVec::grow()](https://junglewise.ai/threats/cve-2019-15551-double-free-in-smallvec)
- [RUSTSEC-2018-0018 - smallvec creates uninitialized value of any type](https://junglewise.ai/threats/cve-2018-25023-use-of-uninitialized-resource-in-smallvec)
