RUSTSEC-2021-0045

FromIterator implementation for Vector/Matrix can drop uninitialized memory

Issued
Package
adtensor (crates.io)
Type
Vulnerability
Categories
  • memory-corruption
Aliases
Details
https://github.com/charles-r-earp/adtensor/issues/4
Patched
no patched versions
Keywords
  • memory-safety

Description

The FromIterator<T> methods for Vector and Matrix rely on the type parameter N to allocate space in the iterable.

If the passed in N type parameter is larger than the number of items returned by the iterator, it can lead to uninitialized memory being left in the Vector or Matrix type which gets dropped.

More