-
Notifications
You must be signed in to change notification settings - Fork 15
array-init-cursor doesn't work #293
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
You are right that this is a soundness issue. I will create a fix and yank the unsound crates. You are wrong about the reason though. The reason is that The only known use of this code is in |
This code is also very old at this point, I wonder if it could be written more cleanly given that many functions have been stabilized now. |
For the record, this bug has existed since the code was introduced in 2021 in a8a8047. |
This has been fixed in #294. |
Version 0.2.1 has been released which fixes the issue, all previous versions have been yanked and a RUSTSEC number has been assigned (RUSTSEC-2025-0019). |
I came across this crate during a code audit (ultimately referenced from polars). Not sure where it's used, but it doesn't function as intended and is unsound. Here is a simple reproduction.
The problem is that
write_impl
doesn't actually write to the referenced array. Instead it seems to be reading from the input data, dropping it, and then pointing the underlying slice at the now destroyed input array, resulting in a dangling reference.The text was updated successfully, but these errors were encountered: