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

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

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

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

工具目录

分类

查看所有分类
Loading categories
工具/GitHubGitHub/h4wkst3r/dop2mop
云基础设施安全侦察容器安全漏洞分析信息收集渗透测试云安全DevSecOps身份与访问管理 (IAM)供应链安全红队
4135个月前尚未审核

最受欢迎

查看全部 →

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

探索所有工具

浏览我们的工具集合

查看所有工具 →
分享
GitHub
h4wkst3r/dop2mop

Dop2Mop

OpenGraph 收集器,用于 BloodHound,可映射从 DevOps 到 MLOps 基础设施的攻击路径,收集 CI/CD 管道、服务主体和 ML 平台资源,以进行横向移动分析。

查看仓库

Dop2Mop

一个概念验证的OpenGraph收集器,用于BloodHound,映射从DevOps到MLOps基础设施的攻击路径。

基于Brett Hawkins(@h4wkst3r)的《从DevOps到MLOps基础设施的攻击路径:特权管道》。

目录

  • 致谢
  • 概述
    • 支持的平台
    • 映射的信任边界
  • 安装
    • 可选依赖
  • 快速开始
    • 生成演示数据
    • 导入BloodHound
  • 配置
    • 配置文件
    • 凭据验证
  • CLI参考
    • 命令概述
    • 全局选项
    • dop2mop collect
    • dop2mop demo
  • CLI使用示例
    • 基本收集
    • 单一平台收集
    • 多平台收集
    • GitHub收集示例
    • Azure DevOps收集示例
    • Azure ML收集示例
    • AWS SageMaker收集示例
    • 全环境收集
  • 环境变量
  • 节点类型
    • DevOps节点
    • MLOps节点
    • 身份节点
    • 工件节点
  • 边类型
    • 攻击路径边
    • 结构边
  • 示例查询
  • 自定义图标
    • 上传图标到BloodHound
  • Python API
    • 使用单个收集器
    • 构建自定义图
  • 故障排除
    • 常见问题
  • 许可证

致谢

  • SpecterOps 为BloodHound和OpenGraph

概述

Dop2Mop从DevOps和MLOps平台收集数据,以识别能够实现从CI/CD管道横向移动到机器学习训练基础设施的攻击路径。它输出兼容BloodHound的OpenGraph JSON,用于可视化和分析。

支持的平台

DevOps平台MLOps平台身份提供商
GitHub(Actions、仓库、机密)Azure机器学习Azure AD服务主体
Azure DevOps(管道、服务连接)Amazon SageMakerAWS IAM角色
OIDC/联合身份

映射的信任边界

Dop2Mop建模了研究中识别的五个关键信任边界:

  1. TB1:代码仓库到CI/CD管道 - 代码提交自动触发管道
  2. TB2:服务主体认证 - 管道用于访问ML平台的NHI凭据
  3. TB3:容器工件信任 - 对内部注册表中容器镜像的隐式信任
  4. TB4:作业定义执行 - ML平台执行作业定义时未经验证
  5. TB5:代码反序列化 - 数据集的不安全反序列化(pickle、joblib)

安装```bash

git clone https://github.com/h4wkst3r/dop2mop.git cd dop2mop pip install -r requirements.txt pip install -e .

root@kitploit:~
## 收集内容

每个收集器收集平台特定的资源,并映射它们之间的信任边界:

| 收集器 | 收集的资源 |
|-----------|-------------------|
| **GitHub** | 组织、仓库、工作流、密钥、分支保护规则、OIDC配置、容器镜像引用、S3存储桶引用 |
| **Azure DevOps** | 组织、项目、流水线(YAML)、服务连接(含范围详情)、变量组、代理池、仓库 |
| **Azure ML** | 工作区、计算集群/实例、数据存储、ML环境、已注册模型、作业/实验、在线和批量端点 |
| **SageMaker** | 训练作业、模型、端点、域、笔记本实例、IAM执行角色(含策略分析)、ECR仓库/镜像、S3存储桶(仅限ML相关) |

## 快速开始

### 生成演示数据

查看Dop2Mop效果的最快方式是生成演示数据,展示研究中的攻击场景:```bash
dop2mop demo -o demo.json

导入到BloodHound

  1. 打开BloodHound CE(v8.0+)
  2. 导航至管理 → 文件导入
  3. 上传生成的JSON文件
  4. 使用Cypher查询:```cypher // Azure DevOps to Azure ML Lateral Movement MATCH p=(repo)-[:TriggersPipeline]->(pipeline)-[:UsesServiceConnection]->(svcconn)-[:AuthenticatesAs]->(workspace)-[:CodeExecution]->(compute) RETURN p

// Container Image Poisoning (Supply Chain Attack) MATCH p=(workflow)-[:CanPoisonImage]->(image)<-[:PullsImage]-(job) RETURN p

// OIDC/Federated Identity Abuse (confirmed edges) MATCH p=(workflow)-[:OIDCTrust]->(oidc)-[:CanAssumeRole]->(role)-[:SubmitsJob]->(job) RETURN p

// OIDC abuse including inferred paths MATCH p=(workflow)-[:OIDCTrust]->(oidc)-[:InferredCanAssumeRole]->(role) RETURN p

// Dataset Poisoning via Pickle Deserialization MATCH p=(workflow)-[:CanPoisonDataset]->(dataset)<-[:LoadsDataset]-(job) RETURN p

// Find repos with weak/no branch protection (TB1 exploitable) MATCH (repo)-[:BypassesProtection]->(repo) RETURN repo.name, repo.default_branch

// Find overprivileged SageMaker IAM roles MATCH (role:IAMRole) WHERE role.is_admin = true OR role.has_s3_full_access = true RETURN role.name, role.attached_policies

// Find SageMaker notebooks with root + internet access MATCH (nb:SMNotebook) WHERE nb.root_access = 'Enabled' AND nb.direct_internet_access = 'Enabled' RETURN nb.name, nb.status

// Find self-hosted ADO agent pools MATCH (agent:ADOAgent) WHERE agent.is_hosted = false RETURN agent.name, agent.pool_type

root@kitploit:~
---

## 配置

### 配置文件

与其每次运行时都传递凭据,不如将它们保存在配置文件中。复制附带的示例并填入你的值:```bash
cp dop2mop.yaml.example dop2mop.yaml
# Edit dop2mop.yaml with your credentials

Dop2Mop 按顺序检查以下位置:

  1. 由 --config 指定的路径
  2. 当前目录下的 dop2mop.yaml / dop2mop.yml / .dop2mop.yaml
  3. ~/.dop2mop.yaml

注意: dop2mop.yaml 已加入 .gitignore,以防止意外提交凭据。示例文件 (dop2mop.yaml.example) 可安全提交。

请参阅 dop2mop.yaml.example 查看所有可用选项及注释。

优先级顺序: CLI 参数 > 配置文件 > 环境变量。

凭据验证

在运行完整收集之前,先测试凭据:```bash

Validate all configured collectors

dop2mop collect --validate -v

Validate specific collectors

dop2mop collect --validate --collectors github,sagemaker -v

root@kitploit:~
这会为每个平台进行轻量级 API 调用,以在开始收集前验证令牌是否有效。

### 收集器别名

你可以使用短名称代替完整的类名与 `--collectors` 参数配合使用:

| 别名 | 收集器 |
|-------|-----------|
| `github`, `gh` | GitHubCollector |
| `ado`, `azuredevops`, `azure-devops` | AzureDevOpsCollector |
| `azureml`, `azure-ml` | AzureMLCollector |
| `sagemaker`, `sm` | SageMakerCollector |```bash
# These are equivalent:
dop2mop collect --collectors GitHubCollector,SageMakerCollector
dop2mop collect --collectors github,sagemaker
dop2mop collect --collectors gh,sm

CLI 参考

命令概览```

dop2mop [options]

Commands: collect Collect data from DevOps/MLOps platforms demo Generate demo data with attack scenarios

root@kitploit:~
### 全局选项

| 选项 | 描述 |
|--------|-------------|
| `-v, --verbose` | 启用详细输出(INFO 级别日志记录) |
| `--debug` | 启用调试输出(DEBUG 级别日志记录) |

---

### `dop2mop collect`

从配置的 DevOps 和 MLOps 平台收集数据。```bash
dop2mop collect [OPTIONS]

常规选项

GitHub 选项

选项描述
--github-token TOKENGitHub 个人访问令牌
--github-org ORGGitHub 组织名称
--github-enterprise-url URLGitHub 企业版服务器 URL

Azure DevOps 选项

选项描述
--azure-devops-token TOKENAzure DevOps 个人访问令牌 (PAT)
--azure-devops-access-token TOKENAzure DevOps 访问令牌(Bearer 认证,可选)
--azure-devops-org ORGAzure DevOps 组织名称

Azure ML 选项

AWS SageMaker 选项

选项描述
--aws-access-key-id KEY

可用收集器


dop2mop demo

生成演示数据,展示研究中的四种攻击场景。```bash dop2mop demo [OPTIONS]

root@kitploit:~
| Option | 描述 |
|--------|------|
| `-o, --output FILE` | 输出文件路径(默认:`dop2mop_demo.json`) |

---

### `dop2mop icons`

为 BloodHound 节点类型生成自定义图标配置。```bash
dop2mop icons [OPTIONS]
选项描述
-o, --output FILE输出文件路径(默认:dop2mop_icons.json)

CLI 使用示例

基础收集```bash

Collect from all configured platforms (uses environment variables)

dop2mop collect -o output.json

Use a config file

dop2mop collect --config dop2mop.yaml -o output.json -v

Validate credentials first, then collect

dop2mop collect --validate -o output.json -v

Collect with verbose logging

dop2mop collect -o output.json -v

Collect with debug logging

dop2mop collect -o output.json --debug

Collect and compress to ZIP

dop2mop collect -o output.json --zip

Limit collection size

dop2mop collect --max-items 100 -o output.json

Skip secret enumeration

dop2mop collect --no-secrets -o output.json

root@kitploit:~
### 单平台集合```bash
# GitHub only (aliases: github, gh)
dop2mop collect --collectors github -o github.json -v

# Azure DevOps only (aliases: ado, azuredevops)
dop2mop collect --collectors ado -o ado.json -v

# Azure ML only (aliases: azureml, azure-ml)
dop2mop collect --collectors azureml -o azureml.json -v

# SageMaker only (aliases: sagemaker, sm)
dop2mop collect --collectors sm -o sagemaker.json -v

多平台收集```bash

GitHub + SageMaker

dop2mop collect --collectors github,sagemaker -o output.json -v

GitHub + Azure DevOps

dop2mop collect --collectors github,ado -o output.json -v

Azure DevOps + Azure ML (full Azure stack)

dop2mop collect --collectors ado,azureml -o azure.json -v

All collectors explicitly

dop2mop collect --collectors github,ado,azureml,sagemaker -o full.json -v

root@kitploit:~
### GitHub 收藏集示例```bash
# Using environment variables
export GITHUB_TOKEN="ghp_xxxxxxxxxxxx"
export GITHUB_ORG="your-org"
dop2mop collect --collectors GitHubCollector -o github.json -v

# Using command-line arguments
dop2mop collect --collectors GitHubCollector \
  --github-token ghp_xxxxxxxxxxxx \
  --github-org your-org \
  -o github.json -v

# GitHub Enterprise Server
dop2mop collect --collectors GitHubCollector \
  --github-token ghp_xxxxxxxxxxxx \
  --github-org your-org \
  --github-enterprise-url https://github.yourcompany.com/api/v3 \
  -o github.json -v

# Skip secret enumeration
dop2mop collect --collectors GitHubCollector \
  --github-token ghp_xxxxxxxxxxxx \
  --github-org your-org \
  --no-secrets \
  -o github.json -v

# Limit to 50 repositories
dop2mop collect --collectors GitHubCollector \
  --github-token ghp_xxxxxxxxxxxx \
  --github-org your-org \
  --max-items 50 \
  -o github.json -v

Azure DevOps 集合示例```bash

Using environment variables

export AZURE_DEVOPS_TOKEN="your-pat" export AZURE_DEVOPS_ORG="your-org" dop2mop collect --collectors AzureDevOpsCollector -o ado.json -v

Using command-line arguments (PAT)

dop2mop collect --collectors AzureDevOpsCollector
--azure-devops-token your-pat
--azure-devops-org your-org
-o ado.json -v

Using access token (Bearer auth)

dop2mop collect --collectors AzureDevOpsCollector
--azure-devops-access-token eyJ0...
--azure-devops-org your-org
-o ado.json -v

root@kitploit:~
> **注意:** Azure DevOps 身份验证优先级:访问令牌(Bearer)> PAT(Basic)。
> 访问令牌可以通过 `az account get-access-token --resource 499b84ac-1321-427f-aa17-267ca6975798` 获取。

### Azure ML 集合示例```bash
# Using environment variables
export AZURE_SUBSCRIPTION_ID="xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
export AZURE_TENANT_ID="xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
dop2mop collect --collectors AzureMLCollector -o azureml.json -v

# Using DefaultAzureCredential (az login)
dop2mop collect --collectors AzureMLCollector \
  --azure-subscription-id xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx \
  --azure-tenant-id xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx \
  -o azureml.json -v

# Using Service Principal
dop2mop collect --collectors AzureMLCollector \
  --azure-subscription-id xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx \
  --azure-tenant-id xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx \
  --azure-client-id xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx \
  --azure-client-secret your-secret \
  -o azureml.json -v

# Using Access Token
dop2mop collect --collectors AzureMLCollector \
  --azure-subscription-id xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx \
  --azure-tenant-id xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx \
  --azure-access-token eyJ0... \
  -o azureml.json -v

注意: Azure ML 身份验证优先级:访问令牌 > 服务主体 > DefaultAzureCredential(az login)。 可以通过 az account get-access-token --resource https://management.azure.com/ 获取访问令牌。

AWS SageMaker 集合示例```bash

Using AWS profile (environment variable)

export AWS_PROFILE="your-profile" dop2mop collect --collectors SageMakerCollector -o sagemaker.json -v

Using AWS profile (command-line)

dop2mop collect --collectors SageMakerCollector
--aws-profile your-profile
-o sagemaker.json -v

Using access keys

dop2mop collect --collectors SageMakerCollector
--aws-access-key-id AKIAXXXXXXXXXXXXXXXX
--aws-secret-access-key xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
--aws-region us-east-1
-o sagemaker.json -v

Different AWS region

dop2mop collect --collectors SageMakerCollector
--aws-profile your-profile
--aws-region us-west-2
-o sagemaker.json -v

root@kitploit:~
### 完整环境收集```bash
# Set all environment variables
export GITHUB_TOKEN="ghp_xxxxxxxxxxxx"
export GITHUB_ORG="your-org"
export AZURE_DEVOPS_TOKEN="your-pat"
export AZURE_DEVOPS_ORG="your-org"
export AZURE_SUBSCRIPTION_ID="xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
export AZURE_TENANT_ID="xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
export AWS_PROFILE="your-profile"

# Collect from all platforms (auto-detects configured collectors)
dop2mop collect -o full_collection.json -v

# Or with explicit collectors
dop2mop collect \
  --collectors GitHubCollector,AzureDevOpsCollector,AzureMLCollector,SageMakerCollector \
  -o full_collection.json -v

环境变量

所有命令行选项都可以通过环境变量设置:

优先级: CLI 参数 > 配置文件 > 环境变量。


节点类型

DevOps 节点

MLOps 节点

身份节点

类型描述
ServicePrincipalAzure AD 服务主体
IAMRoleAWS IAM 角色
OIDCIdentityOIDC 联合身份

工件节点

类型描述
ContainerRegistry容器注册表(ECR、ACR)
ContainerImage容器镜像
S3BucketAWS S3 存储桶

边类型

攻击路径边

推断边

当显式 API 数据不可用时(例如,存储在密钥中的角色 ARN),这些边通过启发式分析创建。它们使用不同的边类型,以便在 BloodHound 查询中过滤。

类型描述
InferredCanAssumeRoleOIDC 身份可能能够承担角色(推断)
InferredSubmitsJob工作流可能通过 OIDC 提交训练作业(推断)

结构边

示例查询

参见 queries/dop2mop_queries.cypher 获取全面的查询示例。


自定义图标

Dop2Mop 在 data/custom_icons.json 中为 BloodHound 自定义节点类型提供了一个预配置的图标文件。

将图标上传到 BloodHound

选项 1:API Explorer(最简单)

  1. 打开 BloodHound CE 并转到 设置 → API Explorer
  2. 找到 POST /api/v2/custom-nodes
  3. 点击 "Try it out"
  4. 粘贴 custom_icons.json 的内容
  5. 点击 "Execute"

选项 2:HMAC 认证(推荐用于自动化)

首先,在 BloodHound 中创建 API 令牌:

  1. 转到 设置 → 管理 → 管理用户
  2. 点击您的用户 → 创建令牌
  3. 保存 令牌 ID 和 令牌密钥

然后使用以下 Python 脚本上传:```python #!/usr/bin/env python3 """Upload custom icons to BloodHound CE using HMAC authentication."""

import base64 import hashlib import hmac import json from datetime import datetime, timezone import requests

Configuration

BLOODHOUND_URL = "http://localhost:8080" TOKEN_ID = "your-token-id" TOKEN_KEY = "your-token-key" ICONS_FILE = "custom_icons.json"

def hmac_auth(method: str, uri: str, body: bytes = b"") -> dict: """Generate HMAC authentication headers.""" digester = hmac.new( base64.b64decode(TOKEN_KEY), msg=None, digestmod=hashlib.sha256 )

root@kitploit:~
now = datetime.now(timezone.utc)
timestamp = now.strftime("%Y-%m-%dT%H:%M:%SZ")

digester.update(f"{method}".encode())
digester.update(f"{uri}".encode())
digester.update(timestamp.encode())
if body:
    digester.update(body)

signature = base64.b64encode(digester.digest()).decode()

return {
    "Authorization": f"bhesignature {TOKEN_ID}",
    "RequestDate": timestamp,
    "Signature": signature,
    "Content-Type": "application/json",
}

def upload_icons(): """Upload custom icons to BloodHound.""" uri = "/api/v2/custom-nodes" url = f"{BLOODHOUND_URL}{uri}"

root@kitploit:~
with open(ICONS_FILE, "rb") as f:
    body = f.read()

headers = hmac_auth("POST", uri, body)
response = requests.post(url, headers=headers, data=body)

print(f"Status: {response.status_code}")
print(f"Response: {response.text}")
return response.status_code == 200

if name == "main": upload_icons()

root@kitploit:~
#### Option 3: Bearer Token (Quick Testing)

从浏览器DevTools的网络选项卡中获取JWT,同时登录到BloodHound:```bash
curl -X POST http://localhost:8080/api/v2/custom-nodes \
  -H "Authorization: Bearer eyJ..." \
  -H "Content-Type: application/json" \
  -d @custom_icons.json

Python API```python

from dop2mop import Dop2MopCollector, CollectorConfig

Configure collection

config = CollectorConfig( github_token="ghp_xxx", github_org="myorg", aws_profile="default", )

Validate credentials first

collector = Dop2MopCollector(config) results = collector.validate_all() print(results) # {'GitHubCollector': True, 'SageMakerCollector': True, ...}

Run collection (supports aliases)

collector.run(collectors=["github", "sm"])

Save output

collector.save("output.json")

Get statistics

print(collector.get_stats())

Get per-collector failure/skip details

print(collector.get_collection_summary())

root@kitploit:~
### 使用独立的收集器```python
from dop2mop import CollectorConfig, GitHubCollector, SageMakerCollector
from dop2mop.graph import OpenGraphBuilder

# Create shared builder
builder = OpenGraphBuilder(source_kind="MLOpsBase")

# Configure
config = CollectorConfig(
    github_token="ghp_xxx",
    github_org="myorg",
    aws_profile="default",
)

# Run individual collectors
github = GitHubCollector(config, builder)
github.collect()

sagemaker = SageMakerCollector(config, builder)
sagemaker.collect()

# Save combined output
builder.save("combined.json")

构建自定义图形```python

from dop2mop.graph import OpenGraphBuilder from dop2mop.models import NodeKind, EdgeType

builder = OpenGraphBuilder(source_kind="CustomSource")

Add nodes

builder.create_node( id="my-pipeline", kinds=[NodeKind.AZURE_DEVOPS_PIPELINE.value], name="My Pipeline", displayname="Production Pipeline", )

builder.create_node( id="my-ml-workspace", kinds=[NodeKind.AZURE_ML_WORKSPACE.value], name="ML Workspace", displayname="Training Workspace", )

Add edge

builder.create_edge( start_id="my-pipeline", end_id="my-ml-workspace", kind=EdgeType.SUBMITS_JOB, properties={"trust_boundary": "TB4"} )

Export

builder.save("custom_graph.json")

root@kitploit:~
---

## 故障排除

### 首先验证

始终从凭证验证开始,及早发现认证问题:```bash
dop2mop collect --validate --collectors github,sm -v

The output will show OK/FAILED per collector before any collection begins.

收集摘要

After every run, Dop2Mop prints a summary showing what was collected and what failed:```

Dop2Mop Collection Summary

Total Nodes: 142 DevOps: 45 MLOps: 38 Identity: 12 Artifact: 47

Total Edges: 201 Contains: 62 TriggersPipeline: 15 ...

──────────────────────────────────────────────────────── Collection Issues: GitHubCollector: 45 collected, 3 failed, 1 skipped FAIL: branch_protection:org/repo - 404 Not Found SKIP: branch_protection:org/private - Insufficient permissions

Output: output.json

root@kitploit:~
### 常见问题

**"GitHub收集器未配置,正在跳过"**
- 确保设置了环境变量 `GITHUB_TOKEN` 和 `GITHUB_ORG`,或者传递 `--github-token` 和 `--github-org` 参数

**"Azure ML收集器未配置,正在跳过"**
- 确保设置了 `AZURE_SUBSCRIPTION_ID` 和 `AZURE_TENANT_ID`
- 如果使用 DefaultAzureCredential,请运行 `az login`
- 或者,使用来自 `az account get-access-token` 的有效令牌传递 `--azure-access-token`

**"SageMaker收集器未配置,正在跳过"**
- 设置 `AWS_PROFILE`,或者同时设置 `AWS_ACCESS_KEY_ID` 和 `AWS_SECRET_ACCESS_KEY`
- 确保凭据具有 SageMaker 读取权限

**分支保护返回403**
- GitHub API 需要管理员权限才能读取分支保护规则
- 非管理员令牌将跳过分支保护收集(在摘要中报告)

**速率限制(429错误)**
- Dop2Mop 在遇到速率限制响应时会自动使用指数退避重试
- 对于大型组织,使用 `--max-items` 减少 API 调用
- GitHub 速率限制:已验证用户 5,000 次请求/小时

**在 BloodHound Cypher 控制台中没有结果**
- 确保查询返回完整节点(`RETURN a, b`),而不是属性(`RETURN a.name, b.name`)
- BloodHound 的 Cypher 控制台用于图形可视化,而不是表格数据
- 对于基于属性的查询,请使用 Neo4j 浏览器(localhost:7474)

**过滤推断边与收集边**
- 推断边使用不同的类型(例如,`InferredCanAssumeRole` 而不是 `CanAssumeRole`)
- 仅查询已确认的边:`MATCH p=()-[:CanAssumeRole]->() RETURN p`
- 查询推断边:`MATCH p=()-[:InferredCanAssumeRole]->() RETURN p`

---

## 许可协议

MIT 许可协议 - 详见 [LICENSE](https://github.com/h4wkst3r/dop2mop/blob/main/LICENSE)。
下载工具
选项描述
-o, --output FILE输出文件路径(默认:dop2mop_output.json)
--zip将输出压缩为 ZIP 文件
--config FILEYAML/JSON 配置文件路径
--validate在收集前验证凭据
--collectors LIST逗号分隔的收集器或别名列表(如 github,sm)
--max-items N每类收集的最大项目数
--no-secrets跳过密钥/凭据枚举
选项描述
--azure-subscription-id IDAzure 订阅 ID
--azure-tenant-id IDAzure AD 租户 ID
--azure-client-id ID服务主体客户端 ID(可选)
--azure-client-secret SECRET服务主体客户端密钥(可选)
--azure-access-token TOKENAzure ML 认证所用的 Azure 访问令牌(可选)
AWS 访问密钥 ID
--aws-secret-access-key SECRETAWS 秘密访问密钥
--aws-region REGIONAWS 区域(默认:us-east-1)
--aws-profile PROFILEAWS CLI 配置文件名称
收集器名称平台所需凭据
GitHubCollectorGitHub--github-token, --github-org
AzureDevOpsCollectorAzure DevOps--azure-devops-token 或 --azure-devops-access-token, --azure-devops-org
AzureMLCollectorAzure ML--azure-subscription-id, --azure-tenant-id
SageMakerCollectorAWS SageMaker--aws-profile 或 --aws-access-key-id
环境变量CLI 等价选项描述
GITHUB_TOKEN--github-tokenGitHub 个人访问令牌
GITHUB_ORG--github-orgGitHub 组织名称
GITHUB_ENTERPRISE_URL--github-enterprise-urlGitHub Enterprise 服务器 URL
AZURE_DEVOPS_TOKEN--azure-devops-tokenAzure DevOps PAT
AZURE_DEVOPS_ACCESS_TOKEN--azure-devops-access-tokenAzure DevOps 访问令牌(Bearer)
AZURE_DEVOPS_ORG--azure-devops-orgAzure DevOps 组织
AZURE_SUBSCRIPTION_ID--azure-subscription-idAzure 订阅 ID
AZURE_TENANT_ID--azure-tenant-idAzure AD 租户 ID
AZURE_CLIENT_ID--azure-client-idAzure 服务主体客户端 ID
AZURE_CLIENT_SECRET--azure-client-secretAzure 服务主体机密
AZURE_ACCESS_TOKEN--azure-access-tokenAzure ML 的访问令牌
AWS_ACCESS_KEY_ID--aws-access-key-idAWS 访问密钥 ID
AWS_SECRET_ACCESS_KEY--aws-secret-access-keyAWS 秘密访问密钥
AWS_REGION--aws-regionAWS 区域(默认:us-east-1)
AWS_PROFILE--aws-profileAWS CLI 配置文件名称
类型描述
GHOrganizationGitHub 组织
GHRepositoryGitHub 仓库
GHWorkflowGitHub Actions 工作流
GHSecretGitHub Actions 密钥
ADOOrganizationAzure DevOps 组织
ADOProjectAzure DevOps 项目
ADOPipelineAzure DevOps 管道
ADOServiceConnectionAzure DevOps 服务连接(NHI)及作用域详情
ADOAgentAzure DevOps 代理池(托管或自托管)
ADOVariableGroupAzure DevOps 变量组
类型描述
AzMLWorkspaceAzure ML 工作区
AzMLComputeAzure ML 计算集群/实例
AzMLExperimentAzure ML 作业/实验
AzMLDatastoreAzure ML 数据存储
AzMLEnvironmentAzure ML 环境(容器定义)
AzMLModelAzure ML 已注册模型
SMDomainSageMaker Studio 域
SMTrainingJobSageMaker 训练作业
SMModelSageMaker 模型
SMEndpointSageMaker 端点(也用于 Azure ML 端点)
SMNotebookSageMaker Notebook 实例
ManagedIdentity
Azure 托管标识
Dataset
ML 数据集
类型信任边界描述
TriggersPipelineTB1代码提交触发 CI/CD
HasBranchProtectionTB1仓库有分支保护规则
BypassesProtectionTB1弱/缺失分支保护(可被利用)
AuthenticatesAsTB2管道使用服务主体
CanAssumeRoleTB2OIDC 身份可承担 IAM 角色
OIDCTrustTB2工作流使用 OIDC 联合
UsesServiceConnectionTB2管道使用 ADO 服务连接
PullsImageTB3训练作业拉取容器镜像
CanPoisonImageTB3管道可修改容器镜像
SubmitsJobTB4服务主体提交 ML 作业
CodeExecutionTB4作业在计算资源上执行代码
LoadsDatasetTB5训练作业加载数据集
CanPoisonDatasetTB5管道可修改数据集
DeserializesTB5不安全的反序列化
InferredPullsImage
训练作业可能拉取被污染的容器镜像(推断)
InferredLoadsDataset训练作业可能加载被污染的数据集(推断)
类型描述
Contains父子关系
MemberOf组成员关系
HasAccessTo访问资源的权限
HasExecutionRole资源使用 IAM/执行角色
Owns所有权关系