Skip to content
Fencer Intel
medium 5.1

CVE-2012-2122 json

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 bef…

published 2012-06-26 14 y ago modified 2026-06-16 4 mo ago also EUVD-2012-2124

cvss
5.1
version 2.0, NVD
cisa kev
Not listed
not in CISA's catalog
epss
96.6%
EPSS 96.6% chance of exploitation in 30 days, percentile 99.8%
public exploits
2
Metasploit, Exploit-DB, plus a Nuclei check

Summary

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.

Patch / fix

  • mysql RHEL 6 5.1.66-1.el6_3
  • mysql-libs RHEL 6 5.1.66-1.el6_3
  • mysql-test RHEL 6 5.1.66-1.el6_3
  • mysql-bench RHEL 6 5.1.66-1.el6_3
  • mysql-server RHEL 6 5.1.66-1.el6_3
  • mysql-embedded RHEL 6 5.1.66-1.el6_3

red hat advisories RHSA-2012:1462

Vendor advisories

What the vendors themselves say about their products: affected, fixed or not affected, and what to do.

red hat product security vex CVE-2012-2122 updated cvss 7.5

mysql: incorrect type cast in check_scramble() leading to authentication bypass

  • Red Hat Enterprise Linux 5 mysql
    affected: no fix available
  • Red Hat Enterprise Linux Desktop (v. 6) mysql 5.1.66-1.el6_3, mysql-libs 5.1.66-1.el6_3, mysql-server 5.1.66-1.el6_3 Red Hat Enterprise Linux Desktop Optional (v. 6) mysql 5.1.66-1.el6_3, mysql-test 5.1.66-1.el6_3, mysql-bench 5.1.66-1.el6_3, mysql-embedded 5.1.66-1.el6_3 Red Hat Enterprise Linux HPC Node (v. 6) mysql 5.1.66-1.el6_3, mysql-libs 5.1.66-1.el6_3 Red Hat Enterprise Linux HPC Node Optional (v. 6) mysql 5.1.66-1.el6_3, mysql-test 5.1.66-1.el6_3, mysql-bench 5.1.66-1.el6_3, mysql-server 5.1.66-1.el6_3, mysql-embedded 5.1.66-1.el6_3 Red Hat Enterprise Linux Server (v. 6) mysql 5.1.66-1.el6_3, mysql-libs 5.1.66-1.el6_3, mysql-test 5.1.66-1.el6_3, mysql-bench 5.1.66-1.el6_3, mysql-server 5.1.66-1.el6_3 Red Hat Enterprise Linux Server Optional (v. 6) mysql 5.1.66-1.el6_3, mysql-embedded 5.1.66-1.el6_3
    +2 more products
    Red Hat Enterprise Linux Workstation (v. 6) mysql 5.1.66-1.el6_3, mysql-libs 5.1.66-1.el6_3, mysql-test 5.1.66-1.el6_3, mysql-bench 5.1.66-1.el6_3, mysql-server 5.1.66-1.el6_3 Red Hat Enterprise Linux Workstation Optional (v. 6) mysql 5.1.66-1.el6_3, mysql-embedded 5.1.66-1.el6_3
    fixed: vendor fix RHSA-2012:1462

Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf

Timeline

  1. First public exploit (Metasploit auxiliary/scanner/mysql/mysql_authbypass_hashdump)
  2. Published

Exploit prediction

96.62% chance of exploitation in the next 30 days, higher than 99.8% of all scored CVEs (FIRST EPSS, 2026-11-09).

Exploits and checks

CVSS scores

assigned by version score vector
NVD 2.0 5.1 AV:N/AC:H/Au:N/C:P/I:P/A:P

Classification

Weakness
Technology feeds

References

Sources

Fencer Intel keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.