A vulnerability (CVE-2026-121481) has been identified in the OpenSSL cryptographic library, leading to a buffer overflow due to integer overflow when processing large amounts of data in the EVP_EncodeBlock() function, which is intended for encoding in Base64 format. The fix is still under discussion and has not been accepted into the OpenSSL codebase. The status of the vulnerability patch in distributions can be assessed on the following pages: Debian, Ubuntu, SUSE, RHEL, Gentoo, Arch, Fedora, FreeBSD.
The issue is caused by the EVP_EncodeBlock() function using the int type when calculating the size of the final buffer based on the size of the input data (in base64, every 3 bytes of input is encoded into 4 output characters), without checking for the possibility of integer overflow. The overflow occurs when more than 1.5 GB of input data is passed and results in returning an incorrect value and allocating a buffer that is intentionally smaller than necessary to hold the result.
When processing external data in EVP_EncodeBlock(), exploitation of the vulnerability for remote code execution is not ruled out, but how applicable the vulnerability is in real-world conditions is still unclear, considering the enormous size of the data leading to the overflow. Attack scenarios currently mentioned include exploitation through scripts using the "openssl s_client" command with the "-proxy_pass" option. For example, it has been shown that when using the GOST engine, OpenSSL does not limit the size of input passwords, which can be transmitted via an environment variable to carry out an attack.
Source: opennet.ru
