VDB
Sign up
CRITICAL9.1

RUSTSEC-2026-0479

Out-of-bounds read when a PEM password callback returns an oversized length

Details

The `*_from_pem_callback` functions, such as `EcKey::private_key_from_pem_callback`, pass the length returned by the user's password callback to OpenSSL without checking it against the size of the buffer the callback was given. If the callback reports more bytes than the buffer holds, some OpenSSL versions read past the end of the buffer while deriving the decryption key. OpenSSL 3.x is not affected.

0.10.78 treats a returned length larger than the buffer as a failed callback.

Are you affected?

Enter the version of the package you're using.

Affected packages

crates.io/openssl
Introduced in: 0.9.0Fixed in: 0.10.78

Upgrade openssl to 0.10.78 or newer (ecosystem crates.io).

References