CVE-2012-2122
CVE-2012-2122 is a medium-severity vulnerability in Oracle Mysql with a CVSS 2.0 base score of 5.1. Its EPSS exploit-prediction score of 96% places it in the 100th percentile, indicating an elevated likelihood of exploitation. The underlying weakness is classified as CWE-287.
Key facts
- Severity: Medium (CVSS 2.0 base score 5.1)
- EPSS exploit prediction: 96% (100th percentile)
- Actively exploited: Not listed in CISA KEV
- Weakness: CWE-287
- Affected product: Oracle Mysql
- Published:
- Last modified:
Description
sql/password.c in Oracle MySQL 5.1.x before 5.1.63, 5.5.x before 5.5.24, and 5.6.x before 5.6.6, and MariaDB 5.1.x before 5.1.62, 5.2.x before 5.2.12, 5.3.x before 5.3.6, and 5.5.x before 5.5.23, when running in certain environments with certain implementations of the memcmp function, allows remote attackers to bypass authentication by repeatedly authenticating with the same incorrect password, which eventually causes a token comparison to succeed due to an improperly-checked return value.
Frequently asked questions
- What is CVE-2012-2122?
- sql/password.c in Oracle MySQL 5.1.x before 5.1.63, 5.5.x before 5.5.24, and 5.6.x before 5.6.6, and MariaDB 5.1.x before 5.1.62, 5.2.x before 5.2.12, 5.3.x before 5.3.6, and 5.5.x before 5.5.23, when running in certain environments with certain implementations of the memcmp function, allows remote attackers to bypass authentication by repeatedly authenticating with the same incorrect password, which eventually causes a token comparison to succeed due to an improperly-checked return value.
- How severe is CVE-2012-2122?
- CVE-2012-2122 has a CVSS 2.0 base score of 5.1, rated medium severity.
- Is CVE-2012-2122 being actively exploited?
- It is not currently listed in CISA's KEV catalog. Its EPSS exploit-prediction score is 96% (100th percentile), an estimate of the probability of exploitation in the next 30 days.
- What products are affected by CVE-2012-2122?
- CVE-2012-2122 primarily affects Oracle Mysql. In total, 61 product configurations (CPEs) are listed as vulnerable; see the affected-products list for the exact versions.
- How do I fix CVE-2012-2122?
- Review the linked vendor and NVD advisories for patched versions and mitigations, then upgrade or apply the recommended workaround.
- When was CVE-2012-2122 published?
- CVE-2012-2122 was published on 2012-06-26 and last updated on 2026-06-16.
References
- http://bugs.mysql.com/bug.php?id=64884
- http://kb.askmonty.org/en/mariadb-5162-release-notes/
- http://lists.opensuse.org/opensuse-security-announce/2012-08/msg00007.html
- http://seclists.org/oss-sec/2012/q2/493
- http://secunia.com/advisories/49417
- http://secunia.com/advisories/53372
- http://security.gentoo.org/glsa/glsa-201308-06.xml
- http://securitytracker.com/id?1027143
- http://www.exploit-db.com/exploits/19092
- http://www.securityfocus.com/bid/53911
- https://community.rapid7.com/community/metasploit/blog/2012/06/11/cve-2012-2122-a-tragically-comedic-security-flaw-in-mysql
Affected products (61)
- cpe:2.3:a:oracle:mysql:5.1.51:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.1.52:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.1.52:sp1:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.1.53:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.1.54:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.1.55:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.1.56:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.1.57:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.1.58:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.1.59:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.1.60:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.1.61:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.5.10:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.5.11:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.5.12:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.5.13:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.5.14:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.5.15:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.5.16:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.5.17:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.5.18:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.5.19:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.5.20:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.5.21:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.6.2:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.6.3:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.6.4:*:*:*:*:*:*:*
- cpe:2.3:a:oracle:mysql:5.6.5:*:*:*:*:*:*:*
- cpe:2.3:a:mariadb:mariadb:5.1.41:*:*:*:*:*:*:*
- cpe:2.3:a:mariadb:mariadb:5.1.42:*:*:*:*:*:*:*
- cpe:2.3:a:mariadb:mariadb:5.1.44:*:*:*:*:*:*:*
- cpe:2.3:a:mariadb:mariadb:5.1.47:*:*:*:*:*:*:*
- cpe:2.3:a:mariadb:mariadb:5.1.49:*:*:*:*:*:*:*
- cpe:2.3:a:mariadb:mariadb:5.1.50:*:*:*:*:*:*:*
- cpe:2.3:a:mariadb:mariadb:5.1.51:*:*:*:*:*:*:*
- cpe:2.3:a:mariadb:mariadb:5.1.53:*:*:*:*:*:*:*
- cpe:2.3:a:mariadb:mariadb:5.1.55:*:*:*:*:*:*:*
- cpe:2.3:a:mariadb:mariadb:5.1.60:*:*:*:*:*:*:*
- cpe:2.3:a:mariadb:mariadb:5.1.61:*:*:*:*:*:*:*
- cpe:2.3:a:mariadb:mariadb:5.2.0:*:*:*:*:*:*:*
More vulnerabilities in Oracle Mysql
- CVE-2012-2750 — Critical (CVSS 10.0): Unspecified vulnerability in MySQL 5.5.x before 5.5.23 has unknown impact and attack vectors related to a "Security…
- CVE-2004-0836 — Critical (CVSS 10.0): Buffer overflow in the mysql_real_connect function in MySQL 4.x before 4.0.21, and 3.x before 3.23.49, allows remote…
- CVE-2020-11656 — Critical (CVSS 9.8): In SQLite through 3.31.1, the ALTER TABLE implementation has a use-after-free, as demonstrated by an ORDER BY clause…
- CVE-2019-14540 — Critical (CVSS 9.8): A Polymorphic Typing issue was discovered in FasterXML jackson-databind before 2.9.10. It is related to…
- CVE-2016-9843 — Critical (CVSS 9.8): The crc32_big function in crc32.c in zlib 1.2.8 might allow context-dependent attackers to have unspecified impact via…
- CVE-2016-9841 — Critical (CVSS 9.8): inffast.c in zlib 1.2.8 might allow context-dependent attackers to have unspecified impact by leveraging improper…
All CVEs affecting Oracle Mysql →
Other CWE-287 (Improper Authentication) vulnerabilities
- CVE-2026-45480 — Critical (CVSS 10.0): Improper authentication in Azure Active Directory allows an unauthorized attacker to elevate privileges over a network.
- CVE-2026-46389 — Critical (CVSS 10.0): UDS Identity Config builds the Keycloak configuration image (realm, plugins, theme, truststore, JARs) consumed by UDS…
- CVE-2026-10611 — Critical (CVSS 10.0): An authentication bypass vulnerability exists in MISP when LDAP mixed authentication is enabled with OTP enforcement.…
- CVE-2026-47280 — Critical (CVSS 10.0): Improper authentication in Azure Resource Manager (ARM) allows an unauthorized attacker to elevate privileges over a…
- CVE-2026-42822 — Critical (CVSS 10.0): Improper authentication in Azure Local Disconnected Operations allows an unauthorized attacker to elevate privileges…
- CVE-2026-20182 — Critical (CVSS 10.0): May 2026: This security advisory provides the details and fix information for a vulnerability that was discovered and…
Browse all CWE-287 (Improper Authentication) vulnerabilities →