RUSTSEC-2026-0473

Source
https://rustsec.org/advisories/RUSTSEC-2026-0473
Import Source
https://github.com/rustsec/advisory-db/blob/osv/crates/RUSTSEC-2026-0473.json
JSON Data
https://api.osv.dev/v1/vulns/RUSTSEC-2026-0473
Aliases
Published
2026-04-19T12:00:00Z
Modified
2026-11-10T14:00:02Z
Summary
Buffer overflow in `Deriver::derive` and `PkeyCtxRef::derive` with OpenSSL 1.1.x
Details

Deriver::derive and PkeyCtxRef::derive pass the length of the caller's buffer to EVP_PKEY_derive and rely on OpenSSL to write no more than that. With OpenSSL 1.1.x, the X25519, X448 and HKDF-extract implementations ignore the length they are given and always write the whole result, so a buffer shorter than the shared secret or derived key is overrun. The overflow is reachable from safe code.

OpenSSL 3.x checks the length itself and is not affected. From 0.10.78, when built against OpenSSL 1.1.x or LibreSSL, both functions derive into a temporary buffer of the required size whenever the caller's buffer is too short, and copy only what fits.

Database specific
{
    "license": "CC0-1.0"
}
References

Affected packages

crates.io / openssl

Package

Name
openssl
View open source insights on deps.dev
Purl
pkg:cargo/openssl

Affected ranges

Type
SEMVER
Events
Introduced
0.9.27
Fixed
0.10.78

Ecosystem specific

{
    "affected_functions": null,
    "affects": {
        "arch": [],
        "functions": [
            "openssl::derive::Deriver::derive",
            "openssl::pkey_ctx::PkeyCtxRef::derive"
        ],
        "os": []
    }
}

Database specific

categories
[
    "memory-corruption"
]
cvss
null
informational
null
source
"https://github.com/rustsec/advisory-db/blob/osv/crates/RUSTSEC-2026-0473.json"