4.5 KiB
4.5 KiB
title, type, tags, date
| title | type | tags | date | |||||
|---|---|---|---|---|---|---|---|---|
| Blockchain Security Auditor | source |
|
2026-04-20 |
Source File
Summary(用中文描述)
- 核心主题:智能合约安全审计 Agent — 专职发现 DeFi 协议与区块链应用中的漏洞
- 问题域:智能合约安全审计、漏洞检测、形式化验证、攻击向量分析、审计报告撰写
- 方法/机制:自动化静态分析(Slither/Mythril/Echidna)+ 人工逐行代码审查 + 属性化模糊测试 + 经济博弈建模;五步工作流(范围→自动化→人工→经济分析→报告)
- 结论/价值:提供包含可复现 PoC 的专业审计报告,Critical/High 漏洞零遗漏,确保修复建议可直接落地
Key Claims(用中文描述)
- 自动化工具只能捕获约 30% 的真实漏洞,剩余必须依靠人工逐行审查
- 每个发现必须包含 PoC 攻击场景或可估算的影响范围,否则不予记录为正式漏洞
- 漏洞评级为 Critical 的前提:无特殊权限即可直接造成用户资金损失或协议破产
- 永远不要因为函数使用了 OpenZeppelin 库就假定它是安全的 — 误用安全库本身就是一类漏洞
- 审计范围必须覆盖完整调用链,不仅仅是当前函数 — 漏洞隐藏在内部调用和继承合约中
Key Quotes
"Your job is not to make developers feel good — it is to find the bug before the attacker does." — Blockchain Security Auditor 角色定义 "Automated tools catch maybe 30% of real bugs." — 为什么不能跳过人工审查 "Never assume a function is safe because it uses OpenZeppelin — misuse of safe libraries is a vulnerability class of its own." — 核心审计原则 "If it can lose user funds, it is High or Critical — never mark a finding as informational to avoid confrontation." — 漏洞评级原则
Key Concepts
- Reentrancy(重入攻击):外部调用在状态更新前执行,允许攻击者在状态清零前回滚调用链重复提取资金
- Oracle Manipulation(预言机操纵):通过闪电贷在单笔交易内操纵 AMM 储备或价格预言机,导致清算/借贷套利
- Flash Loan Attack(闪电贷攻击):在单笔交易内借用大量资金操纵市场状态,无需抵押的信贷攻击
- Access Control(访问控制):特权函数缺少访问修饰符或被错误配置,可导致权限提升
- Formal Verification(形式化验证):使用符号执行和不变式验证数学证明协议关键属性的正确性
- Checks-Effects-Interactions Pattern:先检查条件、更新状态,再执行外部调用,防止逻辑漏洞
- Slither:Trail of Bits 开源的 Solidity 静态分析框架,高置信度检测器几乎总是真实漏洞
- Mythril:基于符号执行的安全分析工具,深度扫描但速度较慢
- Echidna:属性化模糊测试工具,通过随机交易验证协议不变式
- Foundry / Certora / Halmos:高级形式化验证工具链,用于数学证明合约正确性
- SWC Registry:智能合约弱点分类标准(Smart Contract Weakness Classification)
- DeFiHackLabs / rekt.news:DeFi 攻击事件数据库,用于模式匹配已知漏洞
Key Entities
- Trail of Bits:安全审计机构,开发 Slither、Solc 等关键安全工具
- OpenZeppelin:智能合约标准库(ReentrancyGuard、AccessControl 等),被广泛依赖
- The DAO (2016):以太坊首个重大安全事件,重入攻击导致 360 万 ETH 损失,开创了 DeFi 安全研究领域
- Euler Finance:2023 年遭受 donate-to-reserves 操纵攻击,损失 1.97 亿美元,攻击模板被收录
- Nomad Bridge:2022 年因未初始化代理合约漏洞损失 1.9 亿美元
- Curve Finance:2023 年因 Vyper 编译器 bug 导致多池被攻击,损失超 7000 万美元
Connections
- Agents Orchestrator ← defines role scope ← Blockchain Security Auditor
- Compliance Auditor ← related audit methodology ← Blockchain Security Auditor
- Blockchain Security Auditor ← uses tools ← Slither / Mythril / Echidna
- Blockchain Security Auditor ← draws patterns from ← The DAO (2016) / Euler Finance / Nomad Bridge / Curve Finance
Contradictions
- (无已知冲突 — 该页面为独立角色定义文档,未与其他 Wiki 页面产生直接矛盾)