5.1
MEDIUM CVSS 2.0
CVE-2012-2122
Oracle MySQL/MariaDB SQL Heap-Based Buffer Overflow Authentication Bypass
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.

INFO

Published Date :

June 26, 2012, 6:55 p.m.

Last Modified :

June 16, 2026, 11:41 p.m.

Remotely Exploit :

Yes !
Affected Products

The following products are affected by CVE-2012-2122 vulnerability. Even if cvefeed.io is aware of the exact versions of the products that are affected, the information is not represented in the table below.

ID Vendor Product Action
1 Oracle mysql
1 Mariadb mariadb
CVSS Scores
The Common Vulnerability Scoring System is a standardized framework for assessing the severity of vulnerabilities in software and systems. We collect and displays CVSS scores from various sources for each CVE.
Score Version Severity Vector Exploitability Score Impact Score Source
CVSS 2.0 MEDIUM [email protected]
Solution
Update MySQL and MariaDB to patched versions to fix an authentication bypass vulnerability.
  • Upgrade MySQL to version 5.1.63 or later.
  • Upgrade MySQL to version 5.5.24 or later.
  • Upgrade MySQL to version 5.6.6 or later.
  • Upgrade MariaDB to the latest available version.
Public PoC/Exploit Available at Github

CVE-2012-2122 has a 91 public PoC/Exploit available at Github. Go to the Public Exploits tab to see the list.

CWE - Common Weakness Enumeration

While CVE identifies specific instances of vulnerabilities, CWE categorizes the common flaws or weaknesses that can lead to vulnerabilities. CVE-2012-2122 is associated with the following CWEs:

We scan GitHub repositories to detect new proof-of-concept exploits. Following list is a collection of public exploits and proof-of-concepts, which have been published on GitHub (sorted by the most recently updated).

CVE-2012-2122 - MySQL Authentication Bypass

authentication-bypass credentials database exploit mysql poc mysql-auth-bypass

Python

Updated: 3 days, 21 hours ago
0 stars 0 fork 0 watcher
Born at : July 6, 2026, 3:04 p.m. This repo has been linked 1 different CVEs too.

None

Python PowerShell Shell

Updated: 4 days, 8 hours ago
1 stars 0 fork 0 watcher
Born at : July 4, 2026, 12:49 p.m. This repo has been linked 1 different CVEs too.

None

Makefile C++

Updated: 1 week ago
0 stars 0 fork 0 watcher
Born at : July 2, 2026, 3:17 p.m. This repo has been linked 2 different CVEs too.

ADHICODE - Terminal AI Assistant. Zero Refusal. Full Privacy. Runs 100% Offline.

Shell PowerShell Batchfile Python

Updated: 3 days, 22 hours ago
2 stars 0 fork 0 watcher
Born at : June 29, 2026, 4:11 p.m. This repo has been linked 4 different CVEs too.

A penetration testing automation script in Python. Performs reconnaissance, maps findings to CVEs, generates Metasploit resource scripts, and produces a structured pentest report.

cve cybersecurity ethical-hacking metasploit penetration-testing python vulnerability-assessment

Python

Updated: 2 weeks, 1 day ago
0 stars 0 fork 0 watcher
Born at : June 24, 2026, 5:10 p.m. This repo has been linked 9 different CVEs too.

None

Python

Updated: 1 week, 2 days ago
0 stars 0 fork 0 watcher
Born at : June 23, 2026, 4:09 p.m. This repo has been linked 7 different CVEs too.

None

Dockerfile Python HTML Batchfile CSS

Updated: 2 weeks, 1 day ago
0 stars 0 fork 0 watcher
Born at : June 17, 2026, 11:17 p.m. This repo has been linked 11 different CVEs too.

None

Python HTML

Updated: 2 weeks, 6 days ago
2 stars 0 fork 0 watcher
Born at : June 17, 2026, 10:33 p.m. This repo has been linked 17 different CVEs too.

None

Python Dockerfile Batchfile CSS HTML

Updated: 3 weeks, 1 day ago
0 stars 0 fork 0 watcher
Born at : June 17, 2026, 9:54 p.m. This repo has been linked 11 different CVEs too.

None

Python Dockerfile Batchfile CSS HTML

Updated: 3 weeks, 1 day ago
0 stars 0 fork 0 watcher
Born at : June 17, 2026, 2:28 p.m. This repo has been linked 11 different CVEs too.

A structured 12-week red team engagement documenting every phase of a real-world attack — reconnaissance, exploitation, privilege escalation, lateral movement, Active Directory domination, post-engagement cleanup, and executive-level reporting with CVSS scoring and MITRE ATT&CK framework mapping.

Updated: 1 month ago
0 stars 0 fork 0 watcher
Born at : June 10, 2026, 7:49 a.m. This repo has been linked 3 different CVEs too.

None

Python Shell TypeScript CSS JavaScript

Updated: 1 month ago
0 stars 0 fork 0 watcher
Born at : June 6, 2026, 10:22 p.m. This repo has been linked 11 different CVEs too.

Network Vulnerability Scanner — Python + FastAPI + React

Dockerfile Python HTML CSS JavaScript

Updated: 1 month ago
0 stars 0 fork 0 watcher
Born at : June 6, 2026, 3:45 p.m. This repo has been linked 14 different CVEs too.

Autonomous Red Team AI - Nmap + CVE + LLM Pipeline | ~60% recon time reduction | Tested on DVWA, Metasploitable2, HackTheBox

Python HTML Batchfile Shell

Updated: 1 month, 1 week ago
0 stars 0 fork 0 watcher
Born at : May 26, 2026, 4:43 p.m. This repo has been linked 9 different CVEs too.

Autonomous AI security research platform — 240+ tools, multi-LLM, Burp/Metasploit integration, self-training RL pipeline

ai autonomous-agents bug-bounty burp-suite cybersecurity hacking kali-linux llm metasploit offensive-security pentesting python red-team reinforcement-learning security

Python Makefile TypeScript CSS JavaScript HTML Mako

Updated: 1 week ago
1 stars 0 fork 0 watcher
Born at : May 25, 2026, 9:28 a.m. This repo has been linked 10 different CVEs too.

Results are limited to the first 15 repositories due to potential performance issues.

The following list is the news that have been mention CVE-2012-2122 vulnerability anywhere in the article.

The following table lists the changes that have been made to the CVE-2012-2122 vulnerability over time.

Vulnerability history details can be useful for understanding the evolution of a vulnerability, and for identifying the most recent changes that may impact the vulnerability's severity, exploitability, or other characteristics.

  • CVE Modified by [email protected]

    Jun. 16, 2026

    Action Type Old Value New Value
    Added Affected [{'vendor': 'n/a', 'product': 'n/a', 'versions': [{'status': 'affected', 'version': 'n/a'}]}]
  • Status Change by [email protected]

    Apr. 29, 2026

    Action Type Old Value New Value
  • CVE Modified by af854a3a-2127-422b-91ae-364da2661108

    Nov. 21, 2024

    Action Type Old Value New Value
    Added Reference http://bugs.mysql.com/bug.php?id=64884
    Added Reference http://kb.askmonty.org/en/mariadb-5162-release-notes/
    Added Reference http://lists.opensuse.org/opensuse-security-announce/2012-08/msg00007.html
    Added Reference http://seclists.org/oss-sec/2012/q2/493
    Added Reference http://secunia.com/advisories/49417
    Added Reference http://secunia.com/advisories/53372
    Added Reference http://security.gentoo.org/glsa/glsa-201308-06.xml
    Added Reference http://securitytracker.com/id?1027143
    Added Reference http://www.exploit-db.com/exploits/19092
    Added Reference http://www.securityfocus.com/bid/53911
    Added Reference https://community.rapid7.com/community/metasploit/blog/2012/06/11/cve-2012-2122-a-tragically-comedic-security-flaw-in-mysql
  • CVE Modified by [email protected]

    May. 14, 2024

    Action Type Old Value New Value
  • Initial Analysis by [email protected]

    Jun. 27, 2012

    Action Type Old Value New Value
EPSS is a daily estimate of the probability of exploitation activity being observed over the next 30 days. Following chart shows the EPSS score history of the vulnerability.