Added advisory for undefined behavior in openssl (#2021)

This commit is contained in:
Alex Gaynor
2024-07-21 13:26:54 -04:00
committed by GitHub
parent eb081cbca8
commit 627aa62572

View File

@@ -0,0 +1,17 @@
```toml
[advisory]
id = "RUSTSEC-0000-0000"
package = "openssl"
date = "2024-07-21"
url = "https://github.com/sfackler/rust-openssl/pull/2266"
[affected]
functions = { "openssl::bio::MemBio::get_buf" = ["< 0.10.66, >=0.8.0"] }
[versions]
patched = [">= 0.10.66"]
```
# `MemBio::get_buf` has undefined behavior with empty buffers
Previously, `MemBio::get_buf` called `slice::from_raw_parts` with a null-pointer, which violates the functions invariants, leading to undefined behavior. In debug builds this would produce an assertion failure. This is now fixed.