MySQL
Exploitation and enumeration
Last updated
Was this helpful?
Exploitation and enumeration
Last updated
Was this helpful?
The raptor_udf2.c from can be used for local privilege escalation through MySQL run with root privileges.
Login to mysql using the username and password. Then run these:
Use the function to copy /bin/bash to /tmp/rootbash and set the SUID permission:
Exit out of the MySQL shell (type exit or \q and press Enter) and run the /tmp/rootbash
executable with -p to gain a shell running with root privileges: