# GHSA-5j8w-r7g8-5472: Arrow2 allows double free in `safe` code

- Severity: High (rating, scored by GitHub)
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Published: 2022-03-04T12:00:00.000Z
- Modified: 2023-11-08T04:15:47.037Z
- Also known as: RUSTSEC-2022-0012
- Weaknesses: CWE-415

## Description

The struct `Ffi_ArrowArray` implements `#derive(Clone)` that is inconsistent with
its custom implementation of `Drop`, resulting in a double free when cloned.

Cloning this struct in `safe` results in a segmentation fault, which is unsound.

This derive was removed from this struct. All users are advised to either:
* bump the patch version of this crate (for versions `v0.7,v0.8,v0.9`), or
* migrate to a more recent version of  the crate (when using `<0.7`).

Doing so elimitates this vulnerability (code no longer compiles).

(As written by GitHub Advisory Database.)

## Affected

- arrow2 (crates.io): before 0.7.1; from 0.8.0 before 0.8.2; from 0.9.0 before 0.9.2; from 0.0.0-0 before 0.7.1; from 0.10.0 before 0.10.0

## References

- <https://github.com/jorgecarleitao/arrow2/issues/880> (report, web)
- <https://github.com/jorgecarleitao/arrow2> (package)
- <https://rustsec.org/advisories/RUSTSEC-2022-0012.html> (advisory, web)
- <https://crates.io/crates/arrow2> (package)

## Sources

- GitHub Advisory Database: [GHSA-5j8w-r7g8-5472](https://github.com/advisories/GHSA-5j8w-r7g8-5472), CC-BY-4.0, modified 2023-11-08
- RustSec Advisory Database: [RUSTSEC-2022-0012](https://rustsec.org/advisories/RUSTSEC-2022-0012.html), CC0-1.0, modified 2023-11-08

---

Page: https://cve.day/GHSA-5j8w-r7g8-5472 · Whole record: https://cve.day/GHSA-5j8w-r7g8-5472.json · Rebuilt by cve.day 2026-11-25T22:56:43.092Z
