cve.bz

CVE-2022-0778 Infinite Loop

7.5 highEPSS 73%Fix available

High (7.5). EPSS 73% estimated probability of exploitation activity in the next 30 days. Fixed in openssl-src 111.18.0, 300.0.5.

On this page
The BN_mod_sqrt() function, which computes a modular square root, contains a bug that can cause it to loop forever for non-prime moduli. Internally this function is used when parsing certificates that contain elliptic curve public keys in compressed form or explicit elliptic curve parameters with a base point encoded in compressed form. It is possible to trigger the infinite loop by crafting a certificate that has invalid explicit curve parameters. Since certificate parsing happens prior to verification of the certificate signature, any process that parses an externally supplied certificate may thus be subject to a denial of service attack. The infinite loop can also be reached when parsing crafted private keys as they can contain explicit elliptic curve parameters. Thus vulnerable situations include: - TLS clients consuming server certificates - TLS servers consuming client certificates - Hosting providers taking certificates or private keys from customers - Certificate authorities parsing certification requests from subscribers - Anything else which parses ASN.1 elliptic curve parameters Also any other applications that use the BN_mod_sqrt() where the attacker can control the parameter values are vulnerable to this DoS issue. In the OpenSSL 1.0.2 version the public key is not parsed during initial parsing of the certificate which makes it slightly harder to trigger the infinite loop. However any operation which requires the public key from the certificate will trigger the infinite loop. In particular the attacker can use a self-signed certificate to trigger the loop during verification of the certificate signature. This issue affects OpenSSL versions 1.0.2, 1.1.1 and 3.0. It was addressed in the releases of 1.1.1n and 3.0.2 on the 15th March 2022. Fixed in OpenSSL 3.0.2 (Affected 3.0.0,3.0.1). Fixed in OpenSSL 1.1.1n (Affected 1.1.1-1.1.1m). Fixed in OpenSSL 1.0.2zd (Affected 1.0.2-1.0.2zc).

Severity

CVSS 3.1

7.5 high
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
EPSS
73% (unchanged from 73% a week ago; 73% 30 days ago) estimated probability of exploitation activity in the next 30 days; 99th percentile. Scored 2026-11-15. A forecast for this CVE across the internet, not for your own systems.
CISA's assessment (SSVC)
Exploitation: none · Automatable: yes · Technical impact: partial, assessed 2026-05-22. From CISA's Vulnrichment in the CVE List: whether it is exploited, whether exploiting it can be automated, and how much control it gives.
CWE
CWE-835 Loop with Unreachable Exit Condition (Infinite Loop)
Published
Modified
NVD analysis
Analyzed, since modified
Record from
the NVD, synced

Fix and patched versions

Ask an AI about this CVE

Show the promptExplain CVE-2022-0778 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2022-0778?via=ask-ai-copy and https://cve.bz/cve/CVE-2022-0778?via=ask-ai-copy as the source of truth: what is affected and which versions fix it, whether it is in CISA KEV, public exploits, and its EPSS (an internet-wide 30-day estimate of exploitation activity, not a forecast for my systems). If they give no fixed versions, use the CVE record https://cveawg.mitre.org/api/cve/CVE-2022-0778 or the vendor advisory, not third-party mirrors. Tell me how to check whether I am affected and how to verify a fix. Cite the sources and say where they are uncertain.

Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this CVE's id and public links.

Badge for a README or a site

CVE-2022-0778

An image that stays current: it is drawn from the data each time it is fetched (a host that proxies images, as GitHub does, may show its copy for a while). Markdown:

[![CVE-2022-0778](https://cve.bz/cve/badge/CVE-2022-0778.svg)](https://cve.bz/cve/CVE-2022-0778)

HTML:

<a href="https://cve.bz/cve/CVE-2022-0778"><img src="https://cve.bz/cve/badge/CVE-2022-0778.svg" alt="CVE-2022-0778"></a>

Affected

Versions

From the NVD's CPE matches.

ProductAffected
openssl:opensslfrom 1.0.2 before 1.0.2zd
openssl:opensslfrom 1.1.0 before 1.1.1n
openssl:opensslfrom 3.0.0 before 3.0.2
debian:debian_linux9.0
debian:debian_linux10.0
debian:debian_linux11.0
fedoraproject:fedora34
fedoraproject:fedora36
tenable:nessusbefore 8.15.4
tenable:nessusfrom 10.0.0 before 10.1.2
mariadb:mariadbfrom 10.2.0 before 10.2.42
mariadb:mariadbfrom 10.3.0 before 10.3.33
mariadb:mariadbfrom 10.4.0 before 10.4.23
mariadb:mariadbfrom 10.5.0 before 10.5.14
mariadb:mariadbfrom 10.6.0 before 10.6.6
mariadb:mariadbfrom 10.7.0 before 10.7.2
nodejs:node.jsfrom 12.0.0 through 12.12.0
nodejs:node.jsfrom 12.13.0 before 12.22.11
nodejs:node.jsafter 14.0.0 through 14.14.0
nodejs:node.jsfrom 14.15.0 before 14.19.1
nodejs:node.jsafter 16.0.0 through 16.12.0
nodejs:node.jsfrom 16.13.0 before 16.14.2
nodejs:node.jsafter 17.0.0 before 17.7.2

Packages (OSV)

AdvisoryEcosystemPackageAffectedFixed in
GHSA-x3mh-jvjw-3xwxcrates.ioopenssl-src>=300.0.0 <300.0.5300.0.5
GHSA-x3mh-jvjw-3xwxcrates.ioopenssl-src<111.18.0111.18.0
RUSTSEC-2022-0014crates.ioopenssl-src>=0.0.0-0 <111.18.0
>=300.0.0 <300.0.5
111.18.0, 300.0.5

Linux distributions

DistributionReleasePackageFixed inAdvisory
Debian9openssl1.1.0l-1~deb9u5DLA-2952-1
Debian9openssl1.01.0.2u-1~deb9u7DLA-2953-1
Debian10openssl1.1.1d-0+deb10u8DSA-5103-1
Debian11openssl1.1.1k-1+deb11u2DSA-5103-1
Debian12, 13, 14openssl1.1.1n-1DEBIAN-CVE-2022-0778
Ubuntu18.04:LTSopenssl1.1.1-1ubuntu2.1~18.04.15UBUNTU-CVE-2022-0778 USN-5328-1
Ubuntu18.04:LTSopenssl1.01.0.2n-1ubuntu5.8UBUNTU-CVE-2022-0778 USN-5328-1
Ubuntu20.04:LTSopenssl1.1.1f-1ubuntu2.12UBUNTU-CVE-2022-0778 USN-5328-1
Ubuntu22.04:LTSedk22022.02-3ubuntu0.22.04.4UBUNTU-CVE-2022-0778 USN-7894-1
Ubuntu22.04:LTSnodejs12.22.9~dfsg-1ubuntu3.1UBUNTU-CVE-2022-0778 USN-6457-1
Ubuntu22.04:LTSopenssl3.0.2-0ubuntu1UBUNTU-CVE-2022-0778
Ubuntu24.04:LTSedk22024.02-2ubuntu0.6USN-7894-1
UbuntuPro:14.04:LTSopenssl1.0.1f-1ubuntu2.27+esm5UBUNTU-CVE-2022-0778 USN-5328-2
UbuntuPro:16.04:LTSopenssl1.0.2g-1ubuntu4.20+esm2UBUNTU-CVE-2022-0778 USN-5328-2
UbuntuPro:18.04:LTS, Pro:20.04:LTSedk2no fix listedUBUNTU-CVE-2022-0778
UbuntuPro:FIPS-updates:16.04:LTSopenssl1.0.2g-1ubuntu4.fips.4.20.2UBUNTU-CVE-2022-0778
UbuntuPro:FIPS-updates:18.04:LTSopenssl1.1.1-1ubuntu2.fips.2.1~18.04.15UBUNTU-CVE-2022-0778
2 more for Ubuntu in the JSON and on Ubuntu's page.
Red Hatenterprise_linux:7::client, enterprise_linux:7::server, enterprise_linux:7::workstationopenssl, openssl-libs, openssl-perl and 3 more1:1.0.2k-25.el7_9RHSA-2022:1066
Red Hatenterprise_linux:7::computenodeopenssl-perl, openssl-devel, openssl-static and 1 more1:1.0.2k-25.el7_9RHSA-2022:1066
Red Hatenterprise_linux:7::hypervisorredhat-virtualization-host, redhat-virtualization-host-image-update0:4.3.22-20220330.1.el7_9RHSA-2022:1263
Red Hatenterprise_linux:8::appstreamcompat-openssl10, compat-openssl10-debuginfo, compat-openssl10-debugsource1:1.0.2o-4.el8_6RHSA-2022:5326
Red Hatenterprise_linux:8::baseosopenssl, openssl-libs, openssl-perl and 4 more1:1.1.1k-6.el8_5RHSA-2022:1065
Red Hatenterprise_linux:9::appstreamcompat-openssl11, compat-openssl11-debuginfo, compat-openssl11-debugsource1:1.1.1k-4.el9_0RHSA-2022:4899
Red Hatjboss_core_services:1::el7jbcs-httpd24-apr-util, jbcs-httpd24-apr-util-nss, jbcs-httpd24-apr-util-ldap and 7 more0:1.6.1-91.jbcs.el7RHSA-2022:1389
Red Hatjboss_core_services:1::el7jbcs-httpd24-curl, jbcs-httpd24-libcurl, jbcs-httpd24-libcurl-devel and 1 more0:7.78.0-3.jbcs.el7RHSA-2022:1389
Red Hatjboss_core_services:1::el7jbcs-httpd24-httpd, jbcs-httpd24-mod_ldap, jbcs-httpd24-httpd-devel and 5 more0:2.4.37-80.jbcs.el7RHSA-2022:1389
Red Hatjboss_core_services:1::el7jbcs-httpd24-mod_cluster-native, jbcs-httpd24-mod_cluster-native-debuginfo0:1.3.16-10.Final_redhat_2.jbcs.el7RHSA-2022:1389
Red Hatjboss_core_services:1::el7jbcs-httpd24-mod_http2, jbcs-httpd24-mod_http2-debuginfo0:1.15.7-22.jbcs.el7RHSA-2022:1389
Red Hatjboss_core_services:1::el7jbcs-httpd24-mod_jk, jbcs-httpd24-mod_jk-ap24, jbcs-httpd24-mod_jk-manual and 1 more0:1.2.48-29.redhat_1.jbcs.el7RHSA-2022:1389
33 more for Red Hat in the JSON and on Red Hat's page.
SUSEEnterprise Storage 6, Enterprise Storage 7, Linux Enterprise High Performance Computing 15 SP1-ESPOS and 21 morezlib1.2.11-3.26.10SUSE-RU-2022:0861-1
SUSEEnterprise Storage 6, Enterprise Storage 7, Linux Enterprise Module for Legacy 15 SP3 and 10 moreopenssl-1_0_01.0.2p-3.49.1SUSE-SU-2022:0856-1
SUSEEnterprise Storage 6, Linux Enterprise High Performance Computing 15 SP1-ESPOS, Linux Enterprise High Performance Computing 15 SP1-LTSS and 3 moreopenssl-1_11.1.0i-14.27.1SUSE-SU-2022:0853-1
SUSEEnterprise Storage 7, Linux Enterprise High Performance Computing 15 SP2-ESPOS, Linux Enterprise High Performance Computing 15 SP2-LTSS and 10 moreopenssl-1_11.1.1d-11.43.1SUSE-RU-2022:0861-1
SUSEEnterprise Storage 7, Linux Enterprise High Performance Computing 15 SP2-ESPOS, Linux Enterprise High Performance Computing 15 SP2-LTSS and 9 morelinux-glibc-devel5.3-3.2.10SUSE-RU-2022:0861-1
SUSEEnterprise Storage 7, Linux Enterprise High Performance Computing 15 SP2-ESPOS, Linux Enterprise High Performance Computing 15 SP2-LTSS and 7 morenodejs1212.22.12-150200.4.32.1SUSE-SU-2022:1461-1
SUSEEnterprise Storage 7, Linux Enterprise High Performance Computing 15 SP2-ESPOS, Linux Enterprise High Performance Computing 15 SP2-LTSS and 7 morenodejs1414.19.1-150200.15.31.1SUSE-SU-2022:1462-1
SUSEHPE Helion OpenStack 8, Linux Enterprise Server 12 SP2-BCL, Linux Enterprise Server 12 SP3-BCL and 4 moreopenssl1.0.2j-60.75.1SUSE-SU-2022:0854-1
SUSELinux Enterprise High Performance Computing 15-ESPOS, Linux Enterprise High Performance Computing 15-LTSS, Linux Enterprise Server 15-LTSS and 1 moreopenssl-1_11.1.0i-4.66.1SUSE-SU-2022:0851-1
SUSELinux Enterprise Micro 5.1, Linux Enterprise Module for Basesystem 15 SP3glibc2.31-150300.20.7SUSE-RU-2022:0861-1
SUSELinux Enterprise Micro 5.1, Linux Enterprise Module for Basesystem 15 SP3, Linux Enterprise Module for Development Tools 15 SP3libxcrypt4.4.15-150300.4.2.41SUSE-RU-2022:0861-1
SUSELinux Enterprise Micro 5.2glibc2.31-150300.20.7SUSE-SU-2022:0861-1
11 more for SUSE in the JSON and on SUSE's page.
openSUSELeap 15.3openssl-1_0_01.0.2p-3.49.1openSUSE-SU-2022:0856-1
openSUSELeap 15.3, Leap 15.4nodejs1212.22.12-150200.4.32.1SUSE-SU-2022:1461-1
openSUSELeap 15.3, Leap 15.4nodejs1414.19.1-150200.15.31.1SUSE-SU-2022:1462-1
openSUSETumbleweedcargo-audit-advisory-db20220323-1.1openSUSE-SU-2024:11953-1
openSUSETumbleweedlibressl3.4.3-1.1openSUSE-SU-2024:11944-1
openSUSETumbleweedopenssl-1_11.1.1n-1.1openSUSE-SU-2024:11933-1
openSUSETumbleweedopenssl-33.0.2-1.1openSUSE-SU-2024:11927-1
openSUSETumbleweedpython-ecdsa0.18.0-1.1openSUSE-SU-2024:12444-1
openSUSETumbleweedpython-ecdsa0.19.1-1.1openSUSE-SU-2025:14965-1
AlmaLinux8compat-openssl101:1.0.2o-4.el8_6ALSA-2022:5326
AlmaLinux8openssl, openssl-libs, openssl-perl and 1 more1:1.1.1k-6.el8_5ALSA-2022:1065
Rocky Linux8compat-openssl101:1.0.2o-4.el8_6RLSA-2022:5326
Rocky Linux8openssl1:1.1.1k-6.el8_5RLSA-2022:1065
Rocky Linux9compat-openssl111:1.1.1k-4.el9_0RLSA-2022:4899
Alpinev3.12, v3.13, v3.14 and 2 moreopenssl1.1.1n-r0ALPINE-CVE-2022-0778
Alpinev3.14libressl3.3.6-r0ALPINE-CVE-2022-0778
Alpinev3.14libretls3.3.3p1-r3ALPINE-CVE-2022-0778
Alpinev3.15libretls3.3.4-r3ALPINE-CVE-2022-0778
Alpinev3.15, v3.16openssl33.0.2-r0ALPINE-CVE-2022-0778
Alpinev3.15, v3.16, v3.17 and 7 morelibressl3.4.3-r0ALPINE-CVE-2022-0778
Alpinev3.15, v3.16, v3.17 and 7 moreopenjdk1111.0.15_p10-r0ALPINE-CVE-2022-0778
Alpinev3.16, v3.17, v3.18 and 6 morelibretls3.5.1-r0ALPINE-CVE-2022-0778
Alpinev3.17, v3.18openssl1.1-compat1.1.1n-r0ALPINE-CVE-2022-0778
Alpinev3.17, v3.18, v3.19 and 5 moreopenssl3.0.2-r0ALPINE-CVE-2022-0778
Alpinev3.19, v3.20, v3.21 and 3 morelighthouse2.2.0-r0ALPINE-CVE-2022-0778
Azure Linux2openssl1.1.1k-12AZL-9051

From the distributions' data via OSV.dev: the Debian Security Tracker; Ubuntu Security Notices © Canonical Ltd., CC BY-SA 4.0; Red Hat Security Data © Red Hat, Inc., CC BY 4.0; SUSE security data, CC BY 4.0; AlmaLinux's OSV database, MIT; Rocky Linux's errata, BSD-3-Clause; the Alpine secdb, CC BY-SA 4.0; Microsoft's Azure Linux vulnerability data, MIT. Modified: reformatted and linked to CVE records. Credits. On the distributions' own pages: Debian · Ubuntu · Red Hat · SUSE · openSUSE · Alpine.

Red Hat

Red Hat rates this Important.

Red Hat's statement

While Red Hat initially stated not to be directly affected by this flaw, after further investigation we found that the versions of OpenSSL as shipped in Red Hat Enterprise Linux 6, 7, and 8 are vulnerable to a denial of service attack through malicious Elliptic Curve parameters. During processing of the parameters OpenSSL will call BN_mod_sqrt() with invalid arguments, causing the process to enter an infinite loop. The invalid EC parameters can be provided to OpenSSL through X.509 certificates (used in TLS connections), through public and private keys, through certificate signing requests and other places where applications process Elliptic Curve parameters. The flaw has been rated as having a security impact of Important. A future update will address this issue in Red Hat Enterprise Linux 6, 7 and 8.

Red Hat's mitigation

Red Hat has investigated whether a possible mitigation exists for this issue, and has not been able to identify a practical example. Please update the affected package as soon as possible.

ProductPackageStateAdvisory
JBoss Core Services for RHEL 8jbcs-httpd24-apr-util-0:1.6.1-91.el8jbcsFixed 2022-04-20RHSA-2022:1389
JBoss Core Services for RHEL 8jbcs-httpd24-curl-0:7.78.0-3.el8jbcsFixed 2022-04-20RHSA-2022:1389
JBoss Core Services for RHEL 8jbcs-httpd24-httpd-0:2.4.37-80.el8jbcsFixed 2022-04-20RHSA-2022:1389
JBoss Core Services for RHEL 8jbcs-httpd24-mod_cluster-native-0:1.3.16-10.Final_redhat_2.el8jbcsFixed 2022-04-20RHSA-2022:1389
JBoss Core Services for RHEL 8jbcs-httpd24-mod_http2-0:1.15.7-22.el8jbcsFixed 2022-04-20RHSA-2022:1389
JBoss Core Services for RHEL 8jbcs-httpd24-mod_jk-0:1.2.48-29.redhat_1.el8jbcsFixed 2022-04-20RHSA-2022:1389
JBoss Core Services for RHEL 8jbcs-httpd24-mod_md-1:2.0.8-41.el8jbcsFixed 2022-04-20RHSA-2022:1389
JBoss Core Services for RHEL 8jbcs-httpd24-mod_security-0:2.9.2-68.GA.el8jbcsFixed 2022-04-20RHSA-2022:1389
JBoss Core Services for RHEL 8jbcs-httpd24-nghttp2-0:1.39.2-41.el8jbcsFixed 2022-04-20RHSA-2022:1389
JBoss Core Services for RHEL 8jbcs-httpd24-openssl-1:1.1.1g-11.el8jbcsFixed 2022-04-20RHSA-2022:1389
Red Hat Advanced Cluster Management for Kubernetes 2rhacm2/management-ingress-rhel8Affected
Red Hat Enterprise Linux 6openssl098eNot affected
Red Hat Enterprise Linux 7openssl098eNot affected
Red Hat Enterprise Linux 7ovmfNot affected
Red Hat Enterprise Linux 8edk2Not affected
Red Hat Enterprise Linux 8shimNot affected
Red Hat Enterprise Linux 9edk2Not affected
Red Hat Enterprise Linux 9opensslNot affected
Red Hat Enterprise Linux 9shimNot affected
Red Hat JBoss Enterprise Application Platform 6opensslOut of support scope
39 more in the JSON and on Red Hat's page.

Contains Red Hat Security Data © Red Hat, Inc., licensed under CC BY 4.0. Source: https://access.redhat.com/security/data. Modified: reformatted. Red Hat's page for CVE-2022-0778.

ICS advisories (CISA)

AdvisoryTitlePublishedSectorsAffectedFixed
ICSA-26-111-07Siemens SCALANCE2026-04-14Communications, Information Technology, Critical ManufacturingSCALANCE W721-1 RJ45 (6GK5721-1FC00-0AA0), SCALANCE W721-1 RJ45 (6GK5721-1FC00-0AB0), SCALANCE W722-1 RJ45 (6GK5722-1FC00-0AA0) and 46 morenone listed
ICSA-25-226-21Siemens BFCClient2025-08-12Critical Manufacturing, Transportation Systems, Energy, Healthcare and Public Health, Financial Services, Government Services and FacilitiesBFCClientnone listed
ICSA-24-046-02Siemens SIDIS Prime2024-02-13MultipleSIDIS Primenone listed
ICSA-23-348-10Siemens SIMATIC S7-15002023-12-12Critical Manufacturing, Transportation Systems, Energy, Healthcare and Public Health, Financial Services, Government Services and FacilitiesSIMATIC S7-1500 CPU 1518-4 PN/DP MFP (6ES7518-4AX00-1AB0), SIMATIC S7-1500 CPU 1518-4 PN/DP MFP (6ES7518-4AX00-1AC0), SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP (6ES7518-4FX00-1AB0) and 2 morenone listed
ICSA-23-143-02Hitachi Energy's RTU500 Series Product (UPDATE B)2023-05-05EnergyRTU500 series CMU Firmware: >=12.0.1|<=12.0.15, RTU500 series CMU Firmware: >=12.2.1|<=12.2.12, RTU500 series CMU Firmware: >=12.4.1|<=12.4.12 and 5 morenone listed
ICSA-23-059-01Hitachi Energy Gateway Station2023-03-06EnergyGateway Station (GWS): 2.0.0.0, Gateway Station (GWS): 2.1.0.0, Gateway Station (GWS): 2.2.0.0 and 5 morenone listed
ICSA-22-272-02Hitachi Energy MicroSCADA Pro X SYS6002022-09-29EnergySYS600: 9.x versions, SYS600: 10.3.1 and earliernone listed
ICSA-22-221-01Mitsubishi Electric Multiple Factory Automation Products (Update B)2022-08-30Critical ManufacturingCC-Link IE TSN Industrial Managed Switch (NZ2MHG-TSNT8F2 NZ2MHG-TSNT4): Version 03 and prior, GOT2000 compatible HMI software (GT SoftGOT2000): Version 1.275M, MELSEC iQ-R Series OPC UA Server Module (RD81OPC96): Version 08 and priornone listed
ICSA-22-167-14Siemens OpenSSL Affected Industrial Products2022-06-14Critical Manufacturing, Transportation Systems, Energy, Healthcare and Public Health, Financial Services, Government Services and FacilitiesIndustrial Edge - OPC UA Connector, Industrial Edge - SIMATIC S7 Connector App, OpenPCS 7 V8.2 and 47 morenone listed
ICSA-22-132-02Mitsubishi Electric MELSOFT iQ AppPortal2022-05-12Critical ManufacturingMELSOFT iQ AppPortal (SW1DND-IQAPL-M): Versions 1.00A through 1.26Cnone listed

From CISA's ICS advisories (CSAF), provided under CISA's notification. Only the facts are shown; each advisory is on CISA's page. Credits.

Detection rules

Ways to detect this CVE, not exploit code: the nuclei template that checks a system for it, and the Suricata and Snort rules that name it. A rule set may ship a rule turned off, so check yours by its sid.

  • Emerging Threats Open ET EXPLOIT Possible OpenSSL Infinite Loop Inducing Cert Inbound via TCP (CVE-2022-0778) sid 2035887
  • Emerging Threats Open ET EXPLOIT Possible OpenSSL Infinite Loop Inducing Cert Inbound via UDP (CVE-2022-0778) sid 2035888

References

Check your stackJSON