5f698806ab
Build Check / build (18.16.1) (push) Has been cancelled
Release / build (18.16.1) (push) Has been cancelled
Cypress Tests / prepare (push) Has been cancelled
Cypress Tests / RedTeamChrome (1, 18.16.1) (push) Has been cancelled
Cypress Tests / RedTeamChrome (2, 18.16.1) (push) Has been cancelled
Cypress Tests / BlueTeamChrome (1, 18.16.1) (push) Has been cancelled
Cypress Tests / BlueTeamChrome (2, 18.16.1) (push) Has been cancelled
Cypress Tests / install (18.16.1) (push) Has been cancelled
235 lines
9.9 KiB
Markdown
235 lines
9.9 KiB
Markdown
<!-- WEHUB_ZH_README -->
|
||
> [!NOTE]
|
||
> 本文档由 WeHub 基于上游 README 翻译整理,属于社区翻译,非官方中文文档。
|
||
> [English](./README.en.md) · [原始项目](https://github.com/cisagov/RedEye) · [上游 README](https://github.com/cisagov/RedEye/blob/HEAD/README.md)
|
||
> 原作者、版权与许可证归属以原始项目及本仓库 LICENSE 文件为准。
|
||
|
||
# **RedEye**:红队 C2 日志可视化
|
||
---
|
||
|
||
## ⚠️ 本仓库目前处于维护模式 ⚠️
|
||
|
||
本 GitHub 仓库已不再积极开发。我们会审核社区提交的 issue 和 pull request 以修复 bug,但不会考虑任何新功能。
|
||
|
||
---
|
||
|
||
<p align="center">
|
||
<img alt="RedEye Screenshot" src="https://github.com/cisagov/RedEye/blob/develop/docs/images/RedEye-Hero-Screenshot.png?raw=true" width="100%"/>
|
||
</p>
|
||
|
||
RedEye 是由 [CISA](https://www.cisa.gov/) 和 [DOE](https://www.energy.gov/)’s [Pacific Northwest National Laboratory](https://www.pnnl.gov/) 开发的开放源代码分析工具,用于协助 [红队(Red Teams)](https://en.wikipedia.org/wiki/Red_team) 可视化和报告命令与控制(C2)活动。该工具允许操作员评估并展示复杂数据、评估缓解策略,并支持针对红队评估做出有效决策。该工具会解析日志(例如来自 [Cobalt Strike](https://www.cobaltstrike.com/), 的日志),并以易于理解的形式呈现数据。用户随后可为工具中显示的活动添加标签和注释。操作员可使用 RedEye 的演示模式向利益相关方展示发现和工作流程。
|
||
|
||
RedEye 可帮助操作员高效完成以下工作:
|
||
|
||
- 回放并演示红队评估活动,按实际发生顺序呈现,而无需手动翻阅数千行日志文本。
|
||
- 展示并评估复杂的评估数据,以支持有效决策。
|
||
- 更清晰地了解红队评估或渗透测试中所采用的攻击路径以及被攻陷的主机。
|
||
|
||
| **红队(Red Team)** | **蓝队(Blue Team)** |
|
||
|:------------:|:-------------:|
|
||
| [](https://cloud.cypress.io/projects/rsybgk/runs) | [](https://cloud.cypress.io/projects/46ahz3/runs) |
|
||
|
||
|
||
## 快速入门
|
||
|
||
1. **下载**适用于您操作系统的最新 RedEye 二进制文件[\*](#platform-support),请前往 [Releases](https://github.com/cisagov/RedEye/releases) 页面。
|
||
2. **选择模式**并**运行服务器**
|
||
- [ **红队模式(Red Team mode)**](#red-team) 启用完整功能集:上传 C2 日志、探索数据并创建演示。_在红队模式下运行必须提供密码。_ 要在红队模式下启动服务器,请在终端中运行以下命令。
|
||
```
|
||
./RedEye --redTeam --password <your_password>
|
||
```
|
||
- [**蓝队模式(Blue Team mode)**](#blue-team)(默认)提供简化的只读 UI,用于审阅红队导出的战役。要在蓝队模式下启动服务器,请在终端中运行以下命令。
|
||
```
|
||
./RedEye # Or simplify double-click the "RedEye" executable
|
||
```
|
||
3. **在浏览器中使用 Web 应用**,访问 http://127.0.0.1:4000. RedEye 二进制文件会在终端窗口中作为服务器运行,并会自动在默认浏览器中打开 Web 应用 UI。必须关闭终端窗口才能退出 RedEye 服务器。
|
||
4. 尝试导入 [gt.redeye](https://github.com/cisagov/RedEye/raw/develop/applications/redeye-e2e/src/fixtures/gt.redeye) 示例数据集以快速上手。或尝试其他[示例数据集](#example-datasets)。
|
||
|
||
_**MacOS 问题** - 首次运行 RedEye 时,您可能会收到“未验证”错误。您必须前往“系统偏好设置”>“安全性与隐私”>“通用”,并点击“仍要打开”。更多信息请参阅 [Apple 支持页面](https://support.apple.com/guide/mac-help/open-a-mac-app-from-an-unidentified-developer-mh40616/)._
|
||
|
||
### 请阅读 [用户指南](https://github.com/cisagov/RedEye/blob/develop/docs/UserGuide.md) 了解 RedEye 的功能集。
|
||
|
||
---
|
||
|
||
## 红队与蓝队模式
|
||
|
||
RedEye 提供两种模式,覆盖红队演练流程的两个阶段。[红队模式](#red-team) 允许导入 C2 数据、编辑已导入数据,以及添加注释和制作演示。在完成战役数据的整理与标注后,红队可将其战役导出为独立的 `.redeye` 文件,并[移交给蓝队](#blue-team-presentation-handoff) 用于报告和修复。[蓝队模式](#blue-team) 以简化的只读模式运行 RedEye,用于查看红队导出的已整理数据。
|
||
|
||
_注意:红队模式和蓝队模式均可从同一个 RedEye 应用程序二进制文件启动。_
|
||
|
||
### 红队
|
||
|
||
下载的二进制文件包含两部分:
|
||
|
||
- `RedEye` 应用程序二进制文件
|
||
- 包含解析器二进制文件的 `parsers` 文件夹(例如 `cobalt-strike-parser` Cobalt Strike 日志解析器二进制文件)
|
||
|
||
在红队模式下运行 RedEye 有三种方式:
|
||
|
||
1. 运行已下载的二进制文件,并传入 `--redTeam` 和密码选项:
|
||
```
|
||
./RedEye --redTeam --password <your_password>
|
||
```
|
||
2. 克隆、安装并直接运行项目(详见[本地构建](#local-build) 章节)。
|
||
3. Docker Compose
|
||
1. 克隆仓库
|
||
2. 更新 `docker-compose.yml` 中的环境变量。
|
||
3. 运行:
|
||
```
|
||
docker-compose -f docker-compose.yml up -d redeye-core
|
||
```
|
||
|
||
### 蓝队
|
||
|
||
蓝队模式是简化的只读 UI,用于展示经红队整理、标注并导出的数据。该模式默认启用,以便蓝队更简单地启动。
|
||
|
||
可通过双击“RedEye”应用程序二进制文件运行蓝队版本。RedEye 默认运行于 http://127.0.0.1:4000,并会自动打开默认浏览器。
|
||
|
||
### 蓝队演示移交
|
||
|
||
如果 `campaigns` 文件夹与 `RedEye` 应用程序位于同一目录,RedEye 将尝试导入其中的任何 `.redeye` 战役文件。战役文件可在红队模式下导出。
|
||
|
||
要为蓝队准备版本,请按以下两步操作:
|
||
|
||
1. 将 `RedEye` 应用程序二进制文件复制到一个空文件夹。
|
||
2. 在同一目录中创建 `campaigns` 文件夹,并将要发送的 `.redeye` 战役文件放入其中。
|
||
|
||
```
|
||
Folder/
|
||
RedEye
|
||
campaigns/
|
||
Campaign-01.redeye
|
||
Campaign-02.redeye
|
||
```
|
||
|
||
也可通过“+ Add Campaign”对话框在蓝队模式下上传 `.redeye` 文件。
|
||
|
||
## 示例数据集
|
||
本仓库中提供可供下载的示例数据集,位于 [./applications/redeye-e2e/src/fixtures](https://github.com/cisagov/RedEye/tree/develop/applications/redeye-e2e/src/fixtures) 文件夹。
|
||
- **gtdataset** - 提供 [gt.redeye](https://github.com/cisagov/RedEye/raw/develop/applications/redeye-e2e/src/fixtures/gt.redeye) 和 [Cobalt Strike Logs](https://github.com/cisagov/RedEye/tree/develop/applications/redeye-e2e/src/fixtures/gtdataset) 两种形式
|
||
- **smalldata** - 提供 [smalldata.redeye](https://github.com/cisagov/RedEye/raw/develop/applications/redeye-e2e/src/fixtures/smalldata.redeye) 和 [Cobalt Strike Logs](https://github.com/cisagov/RedEye/tree/develop/applications/redeye-e2e/src/fixtures/smalldata) 两种形式
|
||
- **testdata** - 提供 [Cobalt Strike Logs](https://github.com/cisagov/RedEye/tree/develop/applications/redeye-e2e/src/fixtures/testdata) 形式
|
||
|
||
您可以使用 [download-directory.github.io](https://download-directory.github.io/) 等工具,仅下载 GitHub 仓库中的某一个文件夹
|
||
|
||
<!--
|
||
## RedEye Server Settings
|
||
RedEye runs as a server and can be setup to serve the UI on a network..
|
||
|
||
***{instructions}***
|
||
-->
|
||
|
||
## RedEye 服务器参数
|
||
|
||
输入 `./Redeye -h` 查看选项
|
||
|
||
```
|
||
-d, --developmentMode [boolean] put the database and server in development mode
|
||
-r, --redTeam [boolean] run the server in red team mode
|
||
--port [number] the port the server should be exposed at
|
||
-p, --password [string] the password for user authentication
|
||
--parsers [string...] A list of parsers to use or a flag to use all parsers in the parsers folder
|
||
-t, --childProcesses [number] max # of child processes the parser can use
|
||
-h, --help display help for command
|
||
```
|
||
|
||
你也可以在与 `RedEye` 二进制文件相邻的位置,通过 `config.json` 文件来配置服务器参数
|
||
```json5
|
||
|
||
{
|
||
"password": "937038570",
|
||
"redTeam": true,
|
||
"parsers": ["cobalt-strike-parser", "brute-ratel-parser"] // or true/false
|
||
}
|
||
```
|
||
|
||
## 本地构建
|
||
|
||
### 所需软件包
|
||
|
||
- [Node.js](https://nodejs.org/en/) >= v16
|
||
- 安装 yarn:`npm install -g yarn`
|
||
- 运行:`yarn install` // 安装所有软件包
|
||
- 运行以下命令之一:
|
||
1. `yarn release:all`,用于构建适用于 Linux、macOS 和 Windows 的二进制文件
|
||
2. `yarn release:(mac|windows|linux)` .
|
||
- 平台选项:
|
||
- mac
|
||
- windows
|
||
- linux
|
||
|
||
## 开发
|
||
|
||
### 环境配置
|
||
|
||
安装 [Node.js](https://nodejs.org/en/) >= v16
|
||
通过 [npm](https://www.npmjs.com/package/yarn) 全局安装 [yarn](https://yarnpkg.com/)
|
||
|
||
```
|
||
npm install -g yarn
|
||
```
|
||
|
||
安装软件包依赖
|
||
|
||
```
|
||
yarn install
|
||
```
|
||
|
||
#### 快速开始开发
|
||
|
||
以开发模式运行项目
|
||
|
||
```sh
|
||
yarn start
|
||
```
|
||
|
||
#### 高级开发
|
||
|
||
建议在两个独立的终端中分别运行服务器和客户端
|
||
|
||
```sh
|
||
yarn start:client
|
||
```
|
||
|
||
...在另一个终端中
|
||
|
||
```sh
|
||
yarn start:server
|
||
```
|
||
|
||
#### 构建
|
||
|
||
构建适用于 Linux、macOS 和 Windows 的二进制文件
|
||
|
||
```shell
|
||
yarn release:all
|
||
```
|
||
|
||
若要构建特定平台版本,将 `all` 替换为平台名称
|
||
|
||
```shell
|
||
yarn release:(mac|windows|linux)
|
||
```
|
||
|
||
## 平台支持
|
||
|
||
- Linux
|
||
- Ubuntu 18 及更高版本
|
||
- Kali Linux 2020.1 及更高版本
|
||
- 其他发行版可能可用,但尚未经过测试
|
||
- macOS
|
||
- El Capitan 及更高版本
|
||
- Windows
|
||
- Windows 7 及更高版本
|
||
- ARM 支持为实验性功能
|
||
|
||
---
|
||
|
||
<div align="center">
|
||
|
||
<img alt="CISA Logo" src="https://github.com/cisagov/RedEye/blob/develop/docs/images/CISA Logo.png?raw=true" height="35%" width="35%"/>
|
||
|
||
<img alt="RedEye Logo" src="https://raw.githubusercontent.com/cisagov/RedEye/2e0279ad4bdc798eb2ee6aa018bcd6ad66079d0e/applications/client/public/logos/Logo-Dark.svg" height="35%" width="35%"/>
|
||
|
||
</div>
|