# Ghost RAT 变体（nbLGX）木马检测

**URL:** <https://forum.90sec.com/t/topic/224>\
**Category:** 信安之路\
**Created:** [2019 年7 月 18 日 03:05 UTC](https://forum.90sec.com/t/topic/224 "2019-07-18T03:05:55Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

作者： ![951907152](https://forum.90sec.com/user_avatar/forum.90sec.com/951907152/32/7964_2.png) [@951907152](https://forum.90sec.com/u/951907152)\
发布日期： [2019 年7 月 18 日 03:05 UTC](https://forum.90sec.com/t/topic/224/1 "2019-07-18T03:05:55Z")

</div>

> 本文作者：Cherishao

# Ghost RAT 变体（nbLGX）木马检测

Gh0st RAT 是一款很老（10年前）的开源的“远程管理工具”，因其自身的有效性，Gh0st RAT及其变体仍然是现存最为广泛使用的RAT工具之一。甚至在很多APT组发起的攻击事件中，我们依旧能看到它的身影。

## Gh0stRAT 简介

Gh0st RAT 为一款开源的远控工具，控制端采用IOCP模型，数据传输采用zlib压缩方式，稳定快速，上线数量无上限，可同时控制上万台主机控制端自动检测CPU使用率调整自己的工作线程, 稳定高效宿主为svchost以系统服务启动,有远程守护线程,上线间隔为两分钟。心跳包机制防止意外掉线支持HTTP和DNS上线两种方式。

远控工具下载  
[http://www.xdowns.com/soft/1/118/2012/Soft\_89639.html](http://www.xdowns.com/soft/1/118/2012/Soft_89639.html)

具备的功能

文件管理、屏幕监视、键盘记录、远程终端、系统管理。

## 传播方式

为了逃避检测，Gh0stRAT会在整个TCP段上使用加密，其传播方式：常采用“永恒之蓝”和“VBs”组合来进行Gh0st RAT的投递。使用普通数字签名证书，伪装成合法软件来绕过杀软。

## 可检测特征

关于新变体的分析细节，你可以通过以下链接进行了解:

> **[Gh0st in the Dshell: Decoding Undocumented Protocols](https://www.sans.org/white-papers/37032)**
>
> While many types of malware use well-documented protocols, such as HTTP, HTTPS, or IRC for command...

从Gh0stRAT的上线通信数据，我们可以发现，Gh0stRAT及其变体中有5 Byte 是固定的，请求远控域名：[mdzz2019.noip.cn](http://mdzz2019.noip.cn)，域名响应上线IP:221.229.207.145。

 ![%E5%9B%9E%E8%BF%9EIP](https://forum.90sec.com/uploads/default/original/2X/8/8648a0b666998d1c5f6c9788690c725c767dda9b.png)  
图-1释放回连IP  
 ![%E5%9B%BA%E5%AE%9A%E5%AD%97%E8%8A%82%E7%89%B9%E5%BE%81](https://forum.90sec.com/uploads/default/original/2X/8/892b570265c56f3f7992515771c3c7d25afeba22.png)  
图-2固定字节特征

故我们可以将：HEX值“eaeeccd3b8”作为检测特征，为了降低其误报，可以对数据流帧长做一定限制：大于等于5Byte、小于218Byte。

## 参考链接

[https://www.alienvault.com/blogs/labs-research/the-odd-case-of-a-gh0strat-variant](https://www.alienvault.com/blogs/labs-research/the-odd-case-of-a-gh0strat-variant)

> **[Gh0st in the Dshell: Decoding Undocumented Protocols](https://www.sans.org/white-papers/37032)**
>
> While many types of malware use well-documented protocols, such as HTTP, HTTPS, or IRC for command...

[https://www.anquanke.com/post/id/150098](https://www.anquanke.com/post/id/150098)

---

<div class="post-metadata">

作者： ![panda](https://forum.90sec.com/user_avatar/forum.90sec.com/panda/32/4495_2.png) [@panda](https://forum.90sec.com/u/panda)\
发布日期： [2019 年7 月 19 日 03:30 UTC](https://forum.90sec.com/t/topic/224/2 "2019-07-19T03:30:46Z")

</div>

看到 by xdowns.com绿盟 还以为是那个绿盟呢……  
这种马没测试过 一直用的蜂鸟
