返回顶部
o

okx-securityOKX安全扫描

Use this skill for security scanning: check transaction safety, is this transaction safe, pre-execution check, security scan, token risk scanning, honeypot detection, DApp/URL phishing detection, message signature safety, malicious transaction detection, approval safety checks, token approval management. Triggers: 'is this token safe', 'check token security', 'honeypot check', 'scan this tx', 'scan this swap tx', 'tx risk check', 'is this URL a scam', 'check if this dapp is safe', 'phishing site

作者: admin | 来源: ClawHub
源自
ClawHub
版本
V 2.2.7
安全检测
已通过
198
下载量
免费
免费
0
收藏
概述
安装方式
版本历史

okx-security

Onchain OS 安全

5个用于代币风险分析、DApp钓鱼检测、交易预执行安全、签名安全和授权管理的命令。

前置检查

每次运行任何 onchainos 命令前,请按顺序执行以下步骤。不要向用户回显常规命令输出;仅在安装、更新或处理失败时提供简短的状态更新。

  1. 1. 获取最新稳定版本:从GitHub API获取最新的稳定版本标签:

curl -sSL https://api.github.com/repos/okx/onchainos-skills/releases/latest

提取 tagname 字段(例如 v1.0.5)到 LATESTTAG。
如果API调用失败且 onchainos 已本地安装,跳过步骤2-3并继续运行命令(用户可能处于离线或速率限制状态;使用旧版本二进制文件比阻塞更好)。如果 onchainos 安装,则停止并告知用户检查网络连接或从 https://github.com/okx/onchainos-skills 手动安装。

  1. 2. 安装或更新:如果未找到 onchainos,或者 ~/.onchainos/lastcheck(Windows上为 $env:USERPROFILE\.onchainos\lastcheck)中的缓存超过12小时:
- 从最新版本标签下载安装程序及其校验和文件: - macOS/Linux: curl -sSL https://raw.githubusercontent.com/okx/onchainos-skills/${LATEST_TAG}/install.sh -o /tmp/onchainos-install.sh curl -sSL https://github.com/okx/onchainos-skills/releases/download/${LATEST_TAG}/installer-checksums.txt -o /tmp/installer-checksums.txt - Windows: Invoke-WebRequest -Uri https://raw.githubusercontent.com/okx/onchainos-skills/${LATEST_TAG}/install.ps1 -OutFile $env:TEMP\onchainos-install.ps1 Invoke-WebRequest -Uri https://github.com/okx/onchainos-skills/releases/download/${LATEST_TAG}/installer-checksums.txt -OutFile $env:TEMP\installer-checksums.txt - 将安装程序的SHA256与 installer-checksums.txt 进行比对。如果不匹配,停止并发出警告——安装程序可能已被篡改。 - 执行:sh /tmp/onchainos-install.sh(Windows上为 & $env:TEMP\onchainos-install.ps1)。 安装程序内部处理版本比较,仅在需要时下载二进制文件。 - 其他失败情况,请指向 https://github.com/okx/onchainos-skills。
  1. 3. 验证二进制文件完整性(每个会话一次):运行 onchainos --version 获取已安装版本(例如 1.0.5 或 2.0.0-beta.0)。将已安装标签构造为 v
下载已安装版本标签(不一定是LATEST_TAG)的 checksums.txt: curl -sSL https://github.com/okx/onchainos-skills/releases/download/v/checksums.txt -o /tmp/onchainos-checksums.txt 查找平台目标并将已安装二进制文件的SHA256与校验和进行比对。 如果不匹配,重新安装(步骤2)并重新验证。如果仍然不匹配,停止并发出警告。 - 平台目标——macOS:arm64->aarch64-apple-darwin,x8664->x8664-apple-darwin;Linux:x8664->x8664-unknown-linux-gnu,aarch64->aarch64-unknown-linux-gnu,i686->i686-unknown-linux-gnu,armv7l->armv7-unknown-linux-gnueabihf;Windows:AMD64->x86_64-pc-windows-msvc,x86->i686-pc-windows-msvc,ARM64->aarch64-pc-windows-msvc - 哈希命令——macOS/Linux:shasum -a 256 ~/.local/bin/onchainos;Windows:(Get-FileHash $env:USERPROFILE\.local\bin\onchainos.exe -Algorithm SHA256).Hash.ToLower()
  1. 4. 检查技能版本漂移(每个会话一次):如果 onchainos --version 比本技能的 metadata.version 更新,显示一次性通知,说明技能可能已过时,并建议用户通过其平台的方法重新安装技能。不要阻止操作。
  2. 命令失败时不要自动重新安装。 报告错误并建议使用 onchainos --version 或从 https://github.com/okx/onchainos-skills 手动重新安装。
  3. 速率限制错误。 如果命令遇到速率限制,共享API密钥可能已被限制。建议在 OKX开发者门户 创建个人密钥。如果用户创建了 .env 文件,提醒他们将 .env 添加到 .gitignore。

故障安全原则(关键)

扫描完成——检测到风险

如果安全扫描成功完成并返回 action: block 或 action: warn,请遵循下面的风险操作优先级规则。代理不得覆盖风险判定。

扫描失败——基础设施错误

如果安全扫描未能完成(网络错误、API超时、速率限制、响应格式错误),代理必须:

  • - 向用户清晰报告错误。
  • 询问用户是否重试扫描或继续执行而不使用扫描结果。
  • 如果用户选择继续,显示警告:

> ⚠️ 安全扫描无法完成。未经验证继续执行——请确保您信任此操作。
  • - 记录跳过的扫描以便审计。

未能完成的安全扫描不等于通过。始终告知用户并让他们做出明确决定。

风险操作优先级规则

block > warn > 安全(空)。顶层的 action 字段反映来自 riskItemDetail 的最高优先级。

action 值风险等级代理行为
(空/null)低风险可以安全继续
warn
中风险 | 显示风险详情,请求用户明确确认 |
| block | 高风险 | 不要继续,显示风险详情,建议取消 |

  • - 即使模拟失败,风险扫描结果仍然有效(simulator.revertReason 可能包含回退原因)。
  • 如果 warnings 字段有内容,扫描已完成但某些数据可能不完整。仍然呈现可用的风险信息。
  • 成功的API响应中,空/null的 action 表示未检测到风险。但如果API调用失败,缺少 action 并不表示安全——请应用故障安全原则。

安全命令不需要钱包登录。它们适用于任何地址。

链名称支持

CLI接受人类可读的链名称并自动解析。

名称chainIndex
XLayerxlayer196
Ethereum
ethereum 或 eth | 1 |
| Solana | solana 或 sol | 501 |
| BSC | bsc 或 bnb | 56 |
| Polygon | polygon 或 matic | 137 |
| Arbitrum | arbitrum 或 arb | 42161 |
| Base | base | 8453 |
| Avalanche | avalanche 或 avax | 43114 |
| Optimism | optimism 或 op | 10 |
| zkSync Era | zksync | 324 |
| Linea | linea | 59144 |
| Scroll | scroll | 534352 |

地址格式说明:EVM地址(0x...)适用于Ethereum/BSC/Polygon/Arbitrum/Base等。Solana地址(Base58)和Bitcoin地址(UTXO)具有不同格式。不要在不同链类型之间混用格式。

命令索引

#命令描述
1onchainos security token-scan代币风险/蜜罐检测(所有链)
2
onchainos security dapp-scan | DApp/URL钓鱼检测(与链无关) | | 3 | onchainos security tx

标签

skill ai

通过对话安装

该技能支持在以下平台通过对话安装:

OpenClaw WorkBuddy QClaw Kimi Claude

方式一:安装 SkillHub 和技能

帮我安装 SkillHub 和 okx-security-1776187443 技能

方式二:设置 SkillHub 为优先技能安装源

设置 SkillHub 为我的优先技能安装源,然后帮我安装 okx-security-1776187443 技能

通过命令行安装

skillhub install okx-security-1776187443

下载

⬇ 下载 okx-security v2.2.7(免费)

文件大小: 12.91 KB | 发布时间: 2026-4-17 15:34

v2.2.7 最新 2026-4-17 15:34
- Updated skill version to 2.2.7.
- Removed the Wallet Tips feature and associated user interaction logic.
- Updated and clarified the Fail-safe Principle: now, if a security scan fails to complete, the agent must ask the user whether to retry or proceed without scan results, and display a clear warning if proceeding.
- Enhanced instructions on error handling: emphasized auditability and letting the user decide explicitly when scan results are unavailable.
- Expanded documentation for supported chain names and indices.
- Added/updated stepwise command flow for risk scanning, installation, and integrity checks.

Archiver·手机版·闲社网·闲社论坛·羊毛社区· 多链控股集团有限公司 · 苏ICP备2025199260号-1

Powered by Discuz! X5.0   © 2024-2025 闲社网·线报更新论坛·羊毛分享社区·http://xianshe.com

p2p_official_large
返回顶部