Mysql 5.0.12 Exploit -

The release of MySQL 5.0.12 in 2005 arrived during a transformative era for the world’s most popular open-source database. However, this specific version became a case study in database security due to several vulnerabilities—most notably a stack-based buffer overflow within the handling of user-defined functions (UDF) and specific GRANT command sequences. The Technical Mechanism

Writing to Disk: Using the INTO DUMPFILE or INTO OUTFILE commands to write a malicious binary to a directory where the server could load plugins. mysql 5.0.12 exploit

Example attack SQL:

Kai exhaled slowly. He now had a backdoor into the operating system. The release of MySQL 5

Exploitation: Depending on the vulnerability, exploitation might involve: Example attack SQL: Kai exhaled slowly

Conclusion

The plugin directory didn’t exist by default in 5.0.12. But the lib directory did. He adjusted the path to C:\\MySQL\\lib\\plugin\\udf.dll.