x402-compute
x402-compute 是合法的云算力供给技能,处理区块链支付和云实例管理。代码质量高,安全设计良好(如移除.env自动加载、OWS路径验证),唯一显著风险是文档中声明的远程脚本执行(CLI安装),但属于行业标准做法。
为什么得出这个结论
1/4 个维度触发声明资源与推断能力基本一致。
提取到 2 个高危 IOC 或外联信号。
没有形成明确的恶意路径。
发现 4 项需要关注的依赖或供应链线索。
风险分是怎么被拉高的
SKILL.md:613 声明了 curl|sh 安装 sgl CLI 的模式,虽然是行业标准但存在供应链风险
requirements.txt 使用 >= 版本约束,存在依赖混淆攻击风险
get_one_time_password.py 将临时密码写入 .compute_password_* 文件(0600权限),风险较低
最关键的证据
远程脚本执行(已声明)
SKILL.md 文档中声明了 `curl -sSf https://grid.x402compute.cc/install.sh | sh` 用于安装节点CLI。这是行业标准做法,但存在供应链风险:远程服务器可被篡改以执行恶意代码。
SKILL.md:613 依赖版本未锁定
requirements.txt 中所有依赖使用 >= 约束(eth-account>=0.8.0, web3>=6.0.0, requests>=2.28.0, solders>=0.20.0),存在依赖混淆攻击风险。
requirements.txt:1 临时凭证文件写入
get_one_time_password.py 将一次性root密码写入 .compute_password_{instance_id} 文件,权限设为0600。虽然密码是一次性的且文件权限受限,但存在磁盘持久化风险。
scripts/get_one_time_password.py:44 文档占位符(非安全风险)
api-reference.md 中包含示例IP地址 1.2.3.4,明显是占位符,非真实敏感数据泄露。
references/api-reference.md:265 声明能力 vs 实际能力
scripts/get_one_time_password.py:44 写入凭证文件 所有脚本仅调用 compute.x402layer.cc 和 grid.x402compute.cc API OWS CLI 通过 subprocess 执行(已验证路径) wallet_signing.py 读取 PRIVATE_KEY 等密钥,环境隔离 可疑产物与外联
curl -sSf https://grid.x402compute.cc/install.sh | sh SKILL.md:613
1.2.3.4 references/api-reference.md:265
https://docs.x402layer.cc/agentic-access/x402-compute SKILL.md:48
https://cloud.x402compute.cc SKILL.md:52
https://compute.x402layer.cc SKILL.md:97
https://grid.x402compute.cc SKILL.md:99
https://staking.x402layer.cc SKILL.md:113
https://grid.x402compute.cc/v1/models?type=systemone SKILL.md:245
https://grid.x402compute.cc/v1/systemone SKILL.md:248
https://compute.x402layer.cc/compute/provision SKILL.md:326
https://compute.x402layer.cc/compute/instances/ SKILL.md:370
https://compute.x402layer.cc/compute/credits/topup SKILL.md:418
依赖与供应链
| 包名 | 版本 | 来源 | 漏洞 | 备注 |
|---|---|---|---|---|
| eth-account | >=0.8.0 | pip | 否 | 无版本锁定 |
| web3 | >=6.0.0 | pip | 否 | 无版本锁定 |
| requests | >=2.28.0 | pip | 否 | 无版本锁定 |
| solders | >=0.20.0 | pip | 否 | 无版本锁定 |
文件构成
scripts/get_one_time_password.py SKILL.md references/processors.md references/api-reference.md scripts/wallet_signing.py references/agent-pods-api.md scripts/solana_signing.py references/multimodal-embeddings.md