ADVISORIES

Vulnerability

CVE-2021-3711

In order to decrypt SM2 encrypted data an application is expected to call the API function EVP_PKEY_decrypt(). Typically an application will call this function twice. The first time, on entry, the "out" parameter can be NULL and, on exit, the "outlen" parameter is populated with the buffer size required to hold the decrypted plaintext. The application can then allocate a sufficiently sized buffer and call EVP_PKEY_decrypt() again, but this time passing a non-NULL value for the "out" parameter. A bug in the implementation of the SM2 decryption code means that the calculation of the buffer size required to hold the plaintext returned by the first call to EVP_PKEY_decrypt() can be smaller than the actual size required by the second call. This can lead to a buffer overflow when EVP_PKEY_decrypt() is called by the application a second time with a buffer that is too small. A malicious attacker who is able present SM2 content for decryption to an application could cause attacker chosen data to overflow the buffer by up to a maximum of 62 bytes altering the contents of other data held after the buffer, possibly changing application behaviour or causing the application to crash. The location of the buffer is application dependent but is typically heap allocated. Fixed in OpenSSL 1.1.1l (Affected 1.1.1-1.1.1k).

26 advisories report this vulnerability, across 8 ecosystems.

Advisories

  • ALPINE-CVE-2021-3711

    In order to decrypt SM2 encrypted data an application is expected to call the API function EVP_PKEY_decrypt(). Typically an application will call this function twice. The first time, on entry, the "out" parameter can be…

    CVE-2021-3711 Alpine Updated 3 November 2026
  • ALPINE-EDGE-CVE-2021-3711
    CVE-2021-3711 Alpine Updated 18 November 2026
  • AZL-6779

    CVE-2021-3711 affecting package openssl for versions less than 1.1.1k-11

    CVE-2021-3711 Azure Linux Updated 21 April 2026
  • DEBIAN-CVE-2021-3711

    In order to decrypt SM2 encrypted data an application is expected to call the API function EVP_PKEY_decrypt(). Typically an application will call this function twice. The first time, on entry, the "out" parameter can be…

    CVE-2021-3711 Debian Updated 9 October 2026
  • DSA-4963-1

    openssl - security update

    CVE-2021-3711CVE-2021-3712 Debian Updated 20 November 2026
  • GHSA-5ww6-px42-wc85

    SM2 Decryption Buffer Overflow

    Critical CVE-2021-3711 crates.io Updated 24 June 2024
  • OESA-2021-1330

    OpenSSL security update

    Critical CVE-2021-3711CVE-2021-3712 openEuler Updated 18 August 2026
  • RUSTSEC-2021-0097

    SM2 Decryption Buffer Overflow

    CVE-2021-3711 crates.io Updated 8 November 2023
  • SUSE-FU-2022:1419-1

    Feature update for grafana

    Known exploited CVE-2021-36222CVE-2021-3711CVE-2021-39226CVE-2021-41174 openSUSE Updated 4 February 2026
  • SUSE-SU-2021:2830-1

    Security update for openssl-1_1

    CVE-2021-3711CVE-2021-3712 SUSE Updated 2 May 2025
  • SUSE-SU-2021:2833-1

    Security update for openssl-1_1

    CVE-2021-3711CVE-2021-3712 SUSE Updated 4 February 2026
  • SUSE-SU-2022:1396-1

    Security update for SUSE Manager Client Tools

    Known exploited CVE-2021-36222CVE-2021-3711CVE-2021-39226CVE-2021-41174 SUSEopenSUSE Updated 4 February 2026
  • SUSE-SU-2022:2134-1

    Security update for SUSE Manager Client Tools

    Known exploited CVE-2021-36222CVE-2021-3711CVE-2021-39226CVE-2021-41174 SUSE Updated 4 February 2026
  • SUSE-SU-2022:3676-1

    Security update for grafana

    Known exploited CVE-2021-36222CVE-2021-3711CVE-2021-41174CVE-2021-41244 SUSE Updated 4 February 2026
  • SUSE-SU-2022:4428-1

    Security update for grafana

    Known exploited CVE-2021-36222CVE-2021-3711CVE-2021-41174CVE-2021-41244 SUSEopenSUSE Updated 4 February 2026
  • SUSE-SU-2022:4437-1

    Security update for SUSE Manager Client Tools

    Known exploited CVE-2021-36222CVE-2021-3711CVE-2021-41174CVE-2021-41244 SUSEopenSUSE Updated 4 February 2026
  • SUSE-SU-2022:4439-1

    Security update for SUSE Manager Client Tools

    Known exploited CVE-2021-36222CVE-2021-3711CVE-2021-41174CVE-2021-41244 SUSE Updated 4 February 2026
  • SUSE-SU-2024:0191-1

    Security Beta update for SUSE Manager Client Tools

    Known exploited CVE-2020-7753CVE-2021-36222CVE-2021-3711CVE-2021-3807 SUSE Updated 4 February 2026
  • SUSE-SU-2024:0196-1

    Security Beta update for SUSE Manager Client Tools and Salt

    Known exploited CVE-2020-7753CVE-2021-20178CVE-2021-20180CVE-2021-20191 SUSE Updated 4 February 2026
  • UBUNTU-CVE-2021-3711

    In order to decrypt SM2 encrypted data an application is expected to call the API function EVP_PKEY_decrypt(). Typically an application will call this function twice. The first time, on entry, the "out" parameter can be…

    CVE-2021-3711 Ubuntu Updated 22 April 2026
  • USN-5051-1

    openssl vulnerabilities

    CVE-2021-3711CVE-2021-3712 Ubuntu Updated 27 April 2026
  • openSUSE-SU-2021:1188-1

    Security update for openssl-1_1

    CVE-2021-3711CVE-2021-3712 openSUSE Updated 4 February 2026
  • openSUSE-SU-2021:2830-1

    Security update for openssl-1_1

    CVE-2021-3711CVE-2021-3712 openSUSE Updated 4 February 2026
  • openSUSE-SU-2024:11127-1

    libopenssl-1_1-devel-1.1.1l-1.2 on GA media

    Known exploited CVE-2006-2937CVE-2006-2940CVE-2006-3738CVE-2006-4339 openSUSE Updated 7 May 2025
  • openSUSE-SU-2024:11816-1

    grafana-8.3.4-1.1 on GA media

    Known exploited CVE-2021-36222CVE-2021-3711CVE-2021-41174CVE-2021-41244 openSUSE Updated 4 February 2026
  • openSUSE-SU-2025:15136-1

    grype-0.92.1-1.1 on GA media

    CVE-2021-3711CVE-2022-2068 openSUSE Updated 22 May 2025

References