Description
MySQL 4.0.23 and earlier, and 4.1.x up to 4.1.10, allows remote authenticated users with INSERT and DELETE privileges to bypass library path restrictions and execute arbitrary libraries by using INSERT INTO to modify the mysql.func table, which is processed by the udf_init function.
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 3.0 | mysql | 3.23.49-8.11 | DSA-707-1 |
Red Hat
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| RHEL 4 | mysql +3 | 4.1.10a-1.RHEL4.1 | RHSA-2005:334 |
| RHEL 3 | mysql +2 | 3.23.58-15.RHEL3.1 | RHSA-2005:334 |
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.
Exploit-DB 1
- MySQL 4.x - CREATE FUNCTION mysql.func Table Arbitrary Library Injection EDB-25210 · remote · Mar 11, 2005 · verified
Sources: PoC-in-GitHub, Metasploit Framework, Exploit-DB — updated daily. Only links are listed; no exploit code is hosted here.
Advisories 2
- RHSA-2005:334 Red Hat Security Advisory: mysql security update Red Hat Security Advisories (RHSA) · Jun 29, 2026
- DSA-707-1 mysql - several Debian Security (DSA / DLA) · Mar 9, 2026
References
- 2005-0009 vendor-advisory
- 20050310 Mysql CREATE FUNCTION mysql.func table arbitrary library injection mailing-list
- DSA-707 vendor-advisory
- RHSA-2005:334 vendor-advisory
- 101864 vendor-advisory
- SUSE-SA:2005:019 vendor-advisory
- USN-96-1 vendor-advisory
- RHSA-2005:348 vendor-advisory
- 20050310 Mysql CREATE FUNCTION mysql.func table arbitrary library injection mailing-list
- APPLE-SA-2005-08-15 vendor-advisory
- MDKSA-2005:060 vendor-advisory
- mysql-udfinit-gain-access(19658) vdb-entry
- GLSA-200503-19 vendor-advisory
- oval:org.mitre.oval:def:10180 vdb-entry signature
- APPLE-SA-2005-08-17 vendor-advisory
- 12781 vdb-entry