Skip to content

Commit edf8af0

Browse files
1millibytedjc
authored andcommitted
Add advistory for hivex
1 parent e6b2161 commit edf8af0

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

crates/hivex/RUSTSEC-0000-0000.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
```toml
2+
[advisory]
3+
id = "RUSTSEC-0000-0000"
4+
5+
package = "hivex"
6+
date = "2026-02-26"
7+
url = "https://codeberg.org/1millibyte/toolsnt/issues/18"
8+
9+
informational = "unsound"
10+
keywords = ["double-free", "use-after-free", "undefined-behavior"]
11+
12+
[affected.functions]
13+
"hivex::Hive::close" = ["= 0.2.0"]
14+
"hivex::Hive::from_handle" = ["= 0.2.0"]
15+
16+
[versions]
17+
patched = [">= 0.2.1"]
18+
```
19+
20+
# Double-free and use-after-free for Hive
21+
`Drop` implementation for `Hive` did perform free, but so did `Hive::close`, which,
22+
at the end of the scope performed `Drop`, therefore triggering double-free.
23+
24+
Additionally, function `Hive::from_handle` was not marked as unsafe, making it,
25+
in combination with `as_handle` easy to clone and trigger double-free in safe
26+
code or triggering UB when using invalid pointer.

0 commit comments

Comments
 (0)