基本信息
lab地址:https://www.hackthebox.eu/home/machines/profile/220
端口扫描

是一个Windows服务器,没有web
enum4linux
使用enum4linux收集信息:

这里能够看到一条信息,其中是一个账号密码:
1 | index: 0x10a9 RID: 0x457 acb: 0x00000210 Account: marko Name: Marko Novak Desc: Account created. Password set to Welcome123! |
但直接使用这个账号密码尝试登录,失败:

这里可以整理出得到的所有用户名:
1 | user:[Administrator] rid:[0x1f4] |
smb_login
使用得到的用户名字典和前面的密码尝试登录,得到一个正确的账号:

1 | melanie:Welcome123! |
user flag
使用这个账号密码登录,得到user.txt:

搜集信息
1 | dir -force = ls -a |


在这个文件中发现了另一个账号的密码:
1 | cmd /c net use X: \\fs01\backups ryan Serv3r4Admin4cc123! |
note.txt
使用ryan账号登录,在桌面发现一个note.txt:

任何系统更改都会在1分钟内恢复,除了管理员账号做的更改
使用whoami /all
查看信息的话,能够发现ryan这个账号在DnsAdmins中:

DNSAdmins to Domain Admins
搜索能够得到:
Windows Privilege Escalation: DNSAdmins to Domain Admins - Server Level DLL Injection
https://www.abhizer.com/windows-privilege-escalation-dnsadmin-to-domaincontroller/
基本就这个流程,参数自己改下
1 | Attack: |
root flag
得到system权限,在Administrator用户桌面得到root.txt:

参考资料
- https://github.com/portcullislabs/enum4linux
- Windows Privilege Escalation: DNSAdmins to Domain Admins - Server Level DLL Injection
https://www.abhizer.com/windows-privilege-escalation-dnsadmin-to-domaincontroller/ - Hackthebox Resolute - YouTube
https://www.youtube.com/watch?v=WydBNOR51_o&t=1s