Advanced Techniques for mysql to use udfs For Elevation of Privilege-to cope with can 'topensharedlibrary' ud

Source: Internet
Author: User
For cantopensharedlibraryudf. dll I believe that many friends who use mysql to raise permissions should not be unfamiliar with it. It is clearly a root user but they are using udf. this error is prompted when a user-defined function is created by dll Elevation of Privilege. In the past, this situation was generally abandoned. After testing, we found that the app server can use udf. dll to escalate permissions by 5.037 when setting up a php environment.

For can't open sharEdLibrary 'UDf. Dll 'I believe many friends who use mysql to escalate permissions should not be unfamiliar with it. It is clearly a root user but they are using udf. this error is prompted when a user-defined function is created by dll Elevation of Privilege. In the past, this situation was generally abandoned.

After testing, we found that appserv was builtPhpThe environment can use udf. dll to escalate permissions by 5.037

The php environment built by apache + php + mysql + phpmyadmin cannot use 5.1

Why can't one of the two systems be used? The reason is very simple because the udf. dll file must be placed in the lib/blugin file under the mysql installation directory to create a user-defined function, and this directory does not exist by default, while mysqlDuMpFileYou cannot create folders when exporting files. In mysql, udf is started from mysql 5.1. the user-defined functions cannot be created when the dll is imported to the system directory. when the dll is imported to the system directory, you cannot create user-defined functions. The mysql version in the system that can be elevation of permission is 5.0.37, And the mysql version in the system that cannot be elevation of permission is 5.1, exactly in line with the above statement.

Execute create fu in an unusable System (5.037)NcTion mycmd return sTrIng soname'udf. the prompt "can't open shared library 'udf" is displayed. dll 'error message, indicating that the user-defined function cannot be created when exported to the system directory. dll is imported to the lib/blugin directory under the mysql installation directory. I already know that the mysql installation directory is: "c: \ program files \ mysql server 5.1 "the directory lin/plugin does not exist yet, we use webshell to create the lib folder in the mysql installation directory, and then create the plugin folder in the udf folder. in php, the dll export path is "c: \ program files \ mysql server 5.1 \ lib \ plugin \ udf. dll ". At this time, you can execute SQL statements such as select mycmd ("net user ");CommandTo be smart...

Create the lib/plugin directory under the mysql installation directory, and then set the udf. the dll file is exported to this directory, which solves the "can't open shared library 'udf in mysql 5.1 and later versions. dll '"is incorrect ....

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.