Description
MySQL 5.5.19 and possibly other versions, and MariaDB 5.5.28a and possibly other versions, when configured to assign the FILE privilege to users who should not have administrative privileges, allows remote authenticated users to gain privileges by leveraging the FILE privilege to create files as the MySQL administrator. NOTE: the vendor disputes this issue, stating that this is only a vulnerability when the administrator does not follow recommendations in the product's installation documentation. NOTE: it could be argued that this should not be included in CVE because it is a configuration issue.
Public exploits
Exploit or proof-of-concept code for this vulnerability is publicly available, which lowers the bar for attackers. Treat it as a reason to patch sooner.
Metasploit 2 modules
-
Oracle MySQL for Microsoft Windows MOF Execution
exploit/windows/mysql/mysql_mof
-
Oracle MySQL for Microsoft Windows FILE Privilege Abuse
exploit/windows/mysql/mysql_start_up
Exploit-DB 3
- Oracle MySQL (Windows) - FILE Privilege Abuse (Metasploit) EDB-35777 · remote · Jan 13, 2015 · verified
- Oracle MySQL (Windows) - MOF Execution (Metasploit) EDB-23179 · remote · Dec 6, 2012 · verified
- MySQL (Linux) - Database Privilege Escalation EDB-23077 · local · Dec 2, 2012 · verified
GitHub 2 repositories
-
Hood3dRob1n/MySQL-Fu.rb ★ 3 · Feb 9, 2013
MySQL-Fu is a Ruby based MySQL Client Script I wrote. It does most of the stuff a normal MySQL client might do: SQL Shell, Update/Delete/Drop Database/Table, Add/Delete Users, Dump Database(s)/Table …
-
w4fz5uck5/UDFPwn-CVE-2012-5613 ★ 0 · Jun 14, 2018
MySQL 4.x/5.0 (Linux) - User-Defined Function (UDF) Dynamic Library (2) automation script.
Sources: PoC-in-GitHub, Metasploit Framework, Exploit-DB — updated daily. Only links are listed; no exploit code is hosted here.
References
- 53372 third-party-advisory
- [oss-security] 20121202 Re: Re: [Full-disclosure] MySQL (Linux) Stack based buffer overrun PoC Zeroday mailing-list
- GLSA-201308-06 vendor-advisory
- [oss-security] 20121202 Re: Re: [Full-disclosure] MySQL (Linux) Stack based buffer overrun PoC Zeroday mailing-list
- SUSE-SU-2013:0262 vendor-advisory
- 20121201 MySQL (Linux) Database Privilege Elevation Zeroday Exploit mailing-list