VDB

CVE-2022-3358

CVE-2022-3358 PUBLISHED CVSS 9.300000190734863 CRITICAL

Using a Custom Cipher with `NID_undef` may lead to NULL encryption

Record from NVD · Published October 11, 2022

openssl-src is fixed in 300.0.10 and 300.0.0 (crates.io)

OpenSSL supports creating a custom cipher via the legacy EVP_CIPHER_meth_new() function and associated function calls. This function was deprecated in OpenSSL 3.0 and application authors are instead encouraged to use the new provider mechanism in order to implement custom ciphers. OpenSSL versions 3.0.0 to 3.0.5 incorrectly handle legacy custom ciphers passed to the EVP_EncryptInit_ex2(), EVP_DecryptInit_ex2() and EVP_CipherInit_ex2() functions (as well as other similarly named encryption and decryption initialisation functions). Instead of using the custom cipher directly it incorrectly tries to fetch an equivalent cipher from the available providers. An equivalent cipher is found based on the NID passed to EVP_CIPHER_meth_new(). This NID is supposed to represent the unique NID for a given cipher. However it is possible for an application to incorrectly pass NID_undef as this value in the call to EVP_CIPHER_meth_new(). When NID_undef is used in this way the OpenSSL encryption/decryption initialisation function will match the NULL cipher as being equivalent and will fetch this from the available providers. This will succeed if the default provider has been loaded (or if a third party provider has been loaded that offers this cipher). Using the NULL cipher means that the plaintext is emitted as the ciphertext. Applications are only affected by this issue if they call EVP_CIPHER_meth_new() using NID_undef and subsequently use it in a call to an encryption/decryption initialisation function. Applications that only use SSL/TLS are not impacted by this issue. Fixed in OpenSSL 3.0.6 (Affected 3.0.0-3.0.5).

EPSS 4.04% · 90.9th percentile

Fixed versions

Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.

PackageEcosystemFixed in
openssl-srccrates.io300.0.10, 300.0.0
openssl-libsAmazon Linux1:3.0.8-1.amzn2023.0.1
opensslAmazon Linux1:3.0.8-1.amzn2023.0.1
opensslAlpine3.0.6-r0
openssl-develAmazon Linux1:3.0.8-1.amzn2023.0.1
opensslconan.io3.0.6

Risk scores

CVSS 4.0
9.300000190734863
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
EPSS Score
4.04%
90.9th percentile

Affected products

VendorProductVersions
opensslopenssl3.0.0

Timeline

  • Oct 11, 2022 CVE Published
  • Oct 12, 2022 EPSS Score (30 in total, the first dated here)
  • Mar 17, 2026 Security Advisory (49 in total, the first dated here)
  • Jun 23, 2026 Coalition ESS Score
  • Nov 21, 2026 Distribution Patch (46 in total, the first dated here)

Query this with the API

The same record, from the CLI:

vulnetix vdb vuln CVE-2022-3358
vulnetix vdb fixes CVE-2022-3358

Or with curl, using the org id and key from your account page:

curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
  "https://api.vdb.vulnetix.com/v2/vuln/CVE-2022-3358/fixes/registry"

The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart

Look up in the Resolve Platform →
$ Lookup Community · 50/day Open Lookup ›