Skip to content
KitploitKITPLOIT
工具博客
提交
工具博客
提交

黑客、渗透测试和网络安全工具,武装您的安全武器库!

Kitploit 是一个黑客、网络安全和渗透测试工具的目录。发现最新的项目更新,查找漏洞、分析系统、自动化测试并加强你的安全。

··订阅源·联系·隐私·© 2026 Kitploit

工具目录

分类

查看所有分类
Loading categories
EAST — 可扩展的 Azure 安全工具 - 文档 | Kitploit
工具/GitHubGitHub/jsa2/east
云基础设施安全漏洞扫描器配置审计渗透测试云安全身份与访问管理 (IAM)日志分析Archived
GitHubjsa2/east

EAST

可扩展的 Azure 安全工具 - 文档

查看仓库
84113年前Kitploit 审核通过

最受欢迎

查看全部 →

发现我们社区最常用的工具。

探索所有工具

浏览我们的工具集合

查看所有工具 →
分享

可扩展的 Azure 安全工具

可扩展的 Azure 安全工具(以下简称 E.A.S.T)是一款用于评估 Azure 及一定程度上 Azure AD 安全控制项的工具。EAST 的主要用途是在 Azure 评估中收集安全数据以进行评价。这些信息(JSON 内容)随后可用于各种报告工具,我们利用这些工具进一步关联和调查数据。

此工具基于 MIT 许可证 授权。

img

image

合作者

  • 正是在下
  • Nixu 云安全团队

目录

  • 可扩展的 Azure 安全工具
  • 合作者
  • 发布说明
  • 重要事项
  • 工具操作
    • 依赖项
    • 控制项
      • 基础
      • 高级
      • 组合
    • 报告
      • 运行 EAST 扫描
        • 详细前提条件(如果您选择不执行“一次性”版本)
        • 登录 Az CLI 并运行扫描
    • 许可
  • 工具操作文档
    • 原则
      • AZ CLI 的使用
      • 加速
    • 参数参考
    • (高度实验性)在仅限浏览器使用的受限环境中运行
    • 开发控制项
    • 更新与示例
      • 审计 Microsoft.Web 提供程序(函数和 Web 应用)
      • Azure RBAC 基线授权
    • 贡献
      • 其他

发布说明

v 0.5

  • 重构:
    • 托管标识角色和 Azure AD 分配现在通过单个模块完成,以前的版本已显过时,且逻辑不再正确。新模块为 miGeneral.js
    • ASB 不再是 ASB,现为 Microsoft 云安全基准测试,请参见 query.js

v 0.4

  • 引入预览分支

    变更:

    • 安装现已考虑 Azure Cloud Shell 更新版本对依赖项的使用(Cloud Shell 现已安装 Node.js v16 版本)

    • 根据公告检查 Databricks 集群类型

      • 审计 Databricks 集群以查找潜在权限提升——此控制项通常需要对 databricks 集群具有权限"
    • content.json 现按键和内容进行排序。这允许通过 git diff HEAD^1 ¹ 进行差异检查,因为 content.json 具有预定的结果顺序

      image

    ¹ ⚠️ 提醒:如果希望检查 content.json 的差异,则需要从 .gitignore 中“取消忽略” content.json,从而将结果暴露给您可能配置的任何上游仓库。

    请谨慎使用此功能,并确保您使用此功能的分支没有设置公共上游

  • 更改编程模式以避免使用较大数据集时可能出现的竞态条件。主要是在 for await 风格循环中将 var 改为 let


重要事项

⚠️ 工具当前状态为 beta

  • 修复、更新等均按“尽力而为”原则进行,不保证时间或修复质量
  • 在日常工作中使用 EAST 之前,我们会进行一些额外调优,例如应用各种运行和环境限制,并熟悉相关环境。因此,我们目前建议仅在测试环境中以 只读权限 运行 EAST。
    • 服务中的大多数调用均指向 Azure Cloud IP,因此在应用出站 IP 限制的加固环境中应能正常工作。这降低了本工具包含恶意包(在 Azure 中无 C2 情况下)进行“回拨”的风险。
      • 基本上,以只读模式运行可大大降低与可能受损的 NPM 包相关的风险(Google 受损的 NPM 包)
      • 错误等: 您可以通过以只读权限运行该工具来保护环境免受此代码中某些错误的影响
  • 大量代码“按原样”提供:意思是它们仅用于生成特定结果;仍需完成大量清理和模块化工作
  • 目前没有测试,除了某些手动检查(在对 main.js 和各种更高级控制项进行更改后运行)
  • 目前阶段的控制项描述并非最终产品,因此我们感谢您提供的反馈,但这不是本工具当前阶段的重心
  • 如名称所示,我们将其用作评估环境的工具。目前不建议在无人监控的情况下运行,也不应在任何接受传入连接的互联网公开服务中运行
  • 目前文档可以说是不完整的
  • EAST 主要关注 PaaS 资源,因为我们大部分的 Azure 评估都专注于此类资源
  • ⚠️ 启动参数未进行输入清理,因为始终假定这些参数的输入是受控的。尽管如此,该工具大量使用 exec() —— 虽然我尚未审查所有路径,但我相信实现 shellcode 执行是轻而易举的。此工具不假设恶意输入,因此建议在将启动参数粘贴到命令行之前先进行审查。

工具操作

依赖项

为减少代码量,我们使用以下依赖项用于运行和美观(感谢这些出色包的维护者)

运行该工具的其他依赖项: 如果您计划在 Azure Cloud Shell 中运行,则无需安装 Azure CLI:

  • 本工具不包含或分发 Microsoft Azure CLI,而是在源系统(例如 Azure Cloud Shell,即运行 EAST 的主要平台)上已安装时使用它

Azure Cloud Shell (BASH) 或适用的 Linux 发行版 / WSL

要求描述安装
✅ AZ CLIAZ CLI 的使用curl -sL https://aka.ms/InstallAzureCLIDeb | sudo bash
✅ Node.js 运行时 14EAST 的 Node.js 运行时使用 NVM 安装

控制项

EAST 提供了三类控制项:基础、高级和组合

无论类型(基础/高级/组合),机器可读的控制项如下所示:```json { "name": "fn-sql-2079", "resource": "/subscriptions/6193053b-408b-44d0-b20f-4e29b9b67394/resourcegroups/rg-fn-2079/providers/microsoft.web/sites/fn-sql-2079", "controlId": "managedIdentity", "isHealthy": true, "id": "/subscriptions/6193053b-408b-44d0-b20f-4e29b9b67394/resourcegroups/rg-fn-2079/providers/microsoft.web/sites/fn-sql-2079", "Description": "\r\n Ensure The Service calls downstream resources with managed identity", "metadata": { "principalId": { "type": "SystemAssigned", "tenantId": "033794f5-7c9d-4e98-923d-7b49114b7ac3", "principalId": "cb073f1e-03bc-440e-874d-5ed3ce6df7f8" }, "roles": [{ "role": [{ "properties": { "roleDefinitionId": "/subscriptions/6193053b-408b-44d0-b20f-4e29b9b67394/providers/Microsoft.Authorization/roleDefinitions/b24988ac-6180-42a0-ab88-20f7382dd24c", "principalId": "cb073f1e-03bc-440e-874d-5ed3ce6df7f8", "scope": "/subscriptions/6193053b-408b-44d0-b20f-4e29b9b67394/resourceGroups/RG-FN-2079", "createdOn": "2021-12-27T06:03:09.7052113Z", "updatedOn": "2021-12-27T06:03:09.7052113Z", "createdBy": "4257db31-3f22-4c0f-bd57-26cbbd4f5851", "updatedBy": "4257db31-3f22-4c0f-bd57-26cbbd4f5851" }, "id": "/subscriptions/6193053b-408b-44d0-b20f-4e29b9b67394/resourceGroups/RG-FN-2079/providers/Microsoft.Authorization/roleAssignments/ada69f21-790e-4386-9f47-c9b8a8c15674", "type": "Microsoft.Authorization/roleAssignments", "name": "ada69f21-790e-4386-9f47-c9b8a8c15674", "RoleName": "Contributor" }] }] }, "category": "Access" },

root@kitploit:~
### 基础

基础控制包括对初始ARM对象的检查,用于简单的“打开/关闭”布尔设置。

**示例:Azure容器注册表管理员用户**

[acr_adminUser](https://github.com/jsa2/east/blob/HEAD/providers/microsoft.containerregistry/functions/acr_adminUser.js)

门户|EAST
-|-
  ![image](https://assets.kitploit.com/production/public/readmes/5701/955386627eceb05ef02ac4f9aed2c6671397ff9f86946fab1422f65c40510e5d.png) | ``if (item.properties?.adminUserEnabled == false ){returnObject.isHealthy = true }``



### 高级

高级控制包括对初始ARM对象之外的检查。通常调用新请求以获取有关范围内资源及其与其他服务关系的进一步信息。


**示例:角色分配**

除了检查订阅的角色分配外,还通过Azure AD条件访问报告对MFA进行额外检查,并确保特权账户不仅受到密码保护(具有客户端机密的SPN)。

**示例:Azure数据工厂**

[ADF_pipeLineRuns](https://github.com/jsa2/east/blob/HEAD/providers/microsoft.datafactory/functions/ADF_pipeLineRuns.js)

Azure数据工厂管道映射将管道、活动和数据目标结合在一起,然后通过所述活动的运行历史检查日志中泄露的机密。

![img](https://assets.kitploit.com/production/public/readmes/5701/bceb35d6b891df36e341228206a02952c46b7a271be23b40d9a72ff76a0c357f.png)

---

### 组合

组合控制将来自管道的两个或多个控制结果结合起来,以形成一个或多个新控制。使用组合解决了EAST的两个用例:
1. 你无法保证管道中返回的控制结果的顺序
2. 你需要从单个检查中返回多个控制结果

**示例:[composite_resolve_alerts](https://github.com/jsa2/east/blob/HEAD/composites/composite_resolve_alerts.js)**

1. 从Microsoft Cloud Defender获取订阅检查的警报
2. 为每个资源提供商的警报形成新的控制

## 报告

EAST并不专注于提供自动化报告生成,因为它主要提供带有控制和评估状态的JSON文件。想法是使用单独的工具创建报告,通过markdown生成脚本和诸如[Pandoc](https://github.com/jgm/pandoc#the-universal-markup-converter)之类的工具,自动化这些报告相当简单。

- 虽然重点不在报告上,但此存储库包含使用pandoc创建报告的自动化示例,以便以单一文档格式轻松阅读结果。

虽然此工具不分发pandoc,但可以在创建报告时使用它,因此添加了以下引用:https://github.com/jgm/pandoc/blob/master/CITATION.cff```
cff-version: 1.2.0
title: Pandoc
message: "If you use this software, please cite it as below."
type: software
url: "https://github.com/jgm/pandoc"
authors:
  - given-names: John
    family-names: MacFarlane
    email: [email protected]
    orcid: 'https://orcid.org/0000-0003-2557-9090'
  - given-names: Albert
    family-names: Krewinkel
    email: [email protected]
    orcid: '0000-0002-9455-0796'
  - given-names: Jesse
    family-names: Rosenthal
    email: [email protected]

运行 EAST 扫描

本部分指导如何在 BASH@linux 或 Azure Cloud Shell 上的 BASH 中运行此工具(显然 Cloud Shell 也是 Linux,但不需要你有自己的 Linux 机器来使用它)。

⚠️ 如果你在 Cloud Shell 中运行该工具,可能需要重新应用一些安装,因为 Cloud Shell 不会保留各种会话设置。

设置并遗忘 Cloud Shell 上的前提条件```bash curl -o- https://raw.githubusercontent.com/jsa2/EAST/preview/sh/initForuse.sh | bash;

root@kitploit:~
[跳转到下一步](#login-az-cli-and-run-the-scan)

#### 详细前提条件(如果你选择不执行“即忘即用”版本)

**前提条件**```bash

git clone https://github.com/jsa2/EAST --branch preview
cd EAST;
npm install

在云 shell 中安装 Pandoc```bash

Get pandoc for reporting (first time only)

wget "https://github.com/jgm/pandoc/releases/download/2.17.1.1/pandoc-2.17.1.1-linux-amd64.tar.gz"; tar xvzf "pandoc-2.17.1.1-linux-amd64.tar.gz" --strip-components 1 -C ~

root@kitploit:~
**在支持APT的发行版上安装pandoc**```bash
# Get pandoc for reporting (first time only)
sudo apt install pandoc

登录 Az CLI 并运行扫描```bash

Relogin is required to ensure token cache is placed on session on cloud shell

az account clear az login

cd EAST

replace the subid below with your subscription ID!

subId=6193053b-408b-44d0-b20f-4e29b9b67394

node ./plugins/main.js --batch=10 --nativescope=true --roleAssignments=true --helperTexts=true --checkAad=true --scanAuditLogs --composites --subInclude=$subId

root@kitploit:~
![img](https://assets.kitploit.com/production/public/readmes/5701/e85a6607ac555d9bbde7a179042df2a344b0a9f004e99f27ade78e0bc20af5b5.gif)





**生成报告**

``cd EAST; node templatehelpers/eastReports.js --doc`` 

- 如果想要在报告中包含所有 Azure 安全基准结果

``cd EAST; node templatehelpers/eastReports.js --doc --asb`` 

**从云 Shell 导出报告**

`` pandoc -s fullReport2.md -f markdown -t docx --reference-doc=pandoc-template.docx -o fullReport2.docx `` 

![image](https://assets.kitploit.com/production/public/readmes/5701/503e773de2e18294b3d74101d8c2eb6f675e1057c838e89703b440650450c374.png)

**Azure DevOps(实验性)**
有一个用于转储管道日志的 Azure DevOps 控件。你可以通过以下示例指定控件运行:``` node ./plugins/main.js --batch=10 --nativescope=true --roleAssignments=true --helperTexts=true --checkAad=true --scanAuditLogs --composites --subInclude=$subId --azdevops "organizationName" ```

--- 
## Licensing

**Community use**
- Share relevant controls across multiple environments as community effort

**Company use**
- Companies have possibility to develop company specific controls which apply to company specific work. Companies can then control these implementations by decision to share, or not share them based on the operating principle of that company. 

**Non IPR components**
- Code logic and functions are under MIT license. since code logic and functions are alredy based on open-source components & vendor API's, it does not make sense to restrict something that is already based on open source

If you use this tool as part of your commercial effort we only require, that you follow the very relaxed terms of [MIT license](https://github.com/jsa2/east/blob/HEAD/LICENSE)

[Read license](https://github.com/jsa2/EAST/blob/public/LICENSE)

---

# Tool operation documentation

## Principles


### AZCLI USE
**Existing tooling enhanced with Node.js runtime**

Use rich and maintained context of [Microsoft Azure CLI](https://github.com/Azure/azure-cli#microsoft-azure-cli) ``login & commands``  with Node.js control flow which supplies enhanced rest-requests and maps results to schema.
 - This tool does not include or distribute Microsoft Azure CLI, but rather uses it when it has been installed on the source system (Such as Azure Cloud Shell, which is primary platform for running EAST)

### Speedup

View more [details](https://github.com/jsa2/east/blob/HEAD/speedup.md)

✅ Using Node.js runtime as orchestrator utilises Nodes asynchronous nature allowing batching of requests. Batching of requests utilizes the full extent of Azure Resource Managers incredible speed. 

✅ Compared to running requests one-by-one, the speedup can be up to 10x, when Node executes the batch of requests instead of single request at time

## Parameters reference


**Example:**
```shell
node ./plugins/main.js --batch=10 --nativescope --roleAssignments --helperTexts=true --checkAad --scanAuditLogs --composites --shuffle --clearTokens``` 

Param| Description | Default if undefined
-|-|-
`` --nativescope `` | Currently mandatory parameter | no values
`` --shuffle `` | Can help with throttling. Shuffles the resource list to reduce the possibility of resource provider throttling threshold being met  | no values 
`` --roleAssignments `` | Checks controls as per [microsoft.authorization](https://github.com/jsa2/east/blob/HEAD/providers/microsoft.authorization/controls/) | no values
`` --includeRG `` | Checks controls with ResourceGroups as per [microsoft.authorization](https://github.com/jsa2/east/blob/HEAD/providers/microsoft.authorization/controls/) | no values
`` --checkAad `` | Checks controls as per [microsoft.azureactivedirectory](https://github.com/jsa2/east/blob/HEAD/providers/microsoft.azureactivedirectory/controls/) | no values
`` --subInclude `` | Defines subscription scope | no default, requires subscriptionID/s, if not defined will enumerate all subscriptions the user have access to
`` --namespace `` | text filter which matches full, or part of the resource ID <br> **example** `` /microsoft.storage/storageaccounts`` all storage accounts in the scope| optional parameter
`` --notIncludes `` | text filter which matches full, or part of the resource ID <br> **example** `` /microsoft.storage/storageaccounts`` all storage accounts in the scope are **excluded**| optional parameter
`` --batch `` | size of batch interval between throttles |5
`` --wait `` | size of batch interval between throttles | 1500
`` --scanAuditLogs `` | optional parameter. When defined in hours will toggle Azure Activity Log scanning for weak authentication events <br> **defined in:** [scanAuditLogs](https://github.com/jsa2/east/blob/HEAD/providers/microsoft.authorization/functions/scanAuditLogs.js) | 24h
`` --composites `` | read [composite](#composite)| no values
`` --clearTokens `` | clears tokens in session folder, use this if you get authorization errors, or have just changed to other `` az login `` account <br> use `` az account clear`` if you want to clear AZ CLI cache too | no values
`` --tag `` | Filter all results in the end based on single tag``--tag=svc=aksdev``  | no values
``--ignorePreCheck``  | use this option when used with browser delegated tokens| no values
``--helperTexts``  | Will append text descriptions from [general](https://github.com/jsa2/east/blob/HEAD/providers/microsoft.general/controls/) to manual controls| no values
``--reprocess``  | Will update results to existing content.json. Useful for incremental runs| no values


**Parameters reference for example report:**
```shell
node templatehelpers/eastReports.js --asb``` 

Param| Description | Default if undefined
-|-|-
`` --asb `` | gets all ASB results available to users | no values
`` --policy `` | gets all Policy results available to users | no values
``  --doc`` | prints pandoc string for export to console | no values

## (Highly experimental) Running in restricted environments where only browser use is available

Read here [Running in restricted environments](https://github.com/jsa2/EAST/tree/DelegationToken#highly-experimental---bypassing-trusted-device-requirements-for-azure-cli-in-highly-restricted-environments-where-apis-are-available-for-browser-sessions)

## Developing controls 
Developer guide including control flow description is here [``dev-guide.md``](https://github.com/jsa2/east/blob/HEAD/dev-guide.md)

        
## Updates and examples
### Auditing Microsoft.Web provider (Functions and web apps)

✅ Check roles that are assigned to function managed identity in Azure AD and all Azure Subscriptions the audit account has access to <br>
✅ Relation mapping, check which keyVaults the function uses across all subs the audit account has access to<br>
✅ Check if Azure AD authentication is enabled
✅ Check that generation of access tokens to the api requires assigment ``.appRoleAssignmentRequired`` <br>
✅ Audit bindings <br>
  - Function or Azure AD Authentication enabled
  - Count and type of triggers
<br>

✅ Check if [SCM](https://docs.microsoft.com/en-us/azure/azure-functions/security-concepts#secure-the-scm-endpoint) and [FTP](https://docs.microsoft.com/en-us/azure/azure-functions/security-concepts#disable-ftp) endpoints are secured 


![image](https://assets.kitploit.com/production/public/readmes/5701/b074ecdbe5d910c416ad2bbc5b5c57295c3f61348d5a8bb35146112959a15be8.png)


### Azure RBAC baseline authorization 

⚠️ Detect principals in privileged subscriptions roles protected only by password-based single factor authentication. 
-  Checks for users without MFA policies applied for set of conditions
-  Checks for ServicePrincipals protected only by password (as opposed to using Certificate Credential, workload federation and or workload identity CA policy)
  
  Maps to [App Registration Best Practices](https://docs.microsoft.com/en-us/azure/active-directory/develop/security-best-practices-for-app-registration#credential-configuration)
- *An unused credential on an application can result in security breach. While it's convenient to use  <span style="color:red">password</span>. secrets as a credential, we strongly recommend that you use x509 certificates as the only credential type for getting tokens for your application*

``✅State healthy`` - **User result example**  
```JSON
{ 
  "subscriptionName": "EAST -msdn",
  "friendlyName": "[email protected]",
    "mfaResults": {
      "oid": "138ac68f-d8a7-4000-8d41-c10ff26a9097",
      "appliedPol": [{
        "GrantConditions": "challengeWithMfa",
        "policy": "baseline",
        "oid": "138ac68f-d8a7-4000-8d41-c10ff26a9097"
      }],
      "checkType": "mfa"
    },
    "basicAuthResults": {
      "oid": "138ac68f-d8a7-4000-8d41-c10aa26a9097",
      "appliedPol": [{
        "GrantConditions": "challengeWithMfa",
        "policy": "baseline",
        "oid": "138ac68f-d8a7-4000-8d41-c10aa26a9097"
      }],
      "checkType": "basicAuth"
      },
    }

⚠️State unHealthy - Application principal example

root@kitploit:~
{ 
  "subscriptionName": "EAST - HoneyPot",
      "friendlyName": "thx138-kvref-6193053b-408b-44d0-b20f-4e29b9b67394",
      "creds": {
        "@odata.context": "https://graph.microsoft.com/beta/$metadata#servicePrincipals(id,displayName,appId,keyCredentials,passwordCredentials,servicePrincipalType)/$entity",
        "id": "babec804-037d-4caf-946e-7a2b6de3a45f",
        "displayName": "thx138-kvref-6193053b-408b-44d0-b20f-4e29b9b67394",
        "appId": "5af1760e-89ff-46e4-a968-0ac36a7b7b69",
        "servicePrincipalType": "Application",
        "keyCredentials": [],
        "passwordCredentials": [],
        "OnlySingleFactor": [{
          "customKeyIdentifier": null,
          "endDateTime": "2023-10-20T06:54:59.2014093Z",
          "keyId": "7df44f81-a52c-4fd6-b704-4b046771f85a",
          "startDateTime": "2021-10-20T06:54:59.2014093Z",
          "secretText": null,
          "hint": null,
          "displayName": null
        }],
        "StrongSingleFactor": []
        }
}

Contributing

Following methods work for contributing for the time being:

  1. Submit a pull request with code / documentation change
  2. Submit a issue
    • issue can be a:
    • ⚠️ Problem (issue)
    • 📝 Feature request
    • ❔Question

Other

  1. By default EAST tries to work with the current depedencies - Introducing new (direct) depedencies is not directly encouraged with EAST. If such vital depedency is introduced, then review licensing of such depedency, and update readme.md - depedencies
    • There is nothing to prevent you from creating your own fork of EAST with your own depedencies
下载工具
包美观运行许可
axios✅MIT
yargs✅MIT
jsonwebtoken✅MIT
chalk✅MIT
js-beautify ✅MIT