测试与安全

smart-contract-vulnerabilities

yaklang/hack-skills

Smart contract vulnerability playbook. Use when auditing Solidity/EVM contracts for reentrancy, integer overflow, access control, delegatecall, flash loan, signature replay, and MEV-related attack patterns.

  • 3590 次安装
  • 2600 星标
  • 收录于

安装命令

npx skills add https://github.com/yaklang/hack-skills --skill smart-contract-vulnerabilities

SKILL.md

SKILL: Smart Contract Vulnerabilities — Expert Attack Playbook

AI LOAD INSTRUCTION: Expert smart contract audit techniques. Covers reentrancy (single, cross-function, cross-contract, read-only), integer overflow, access control, delegatecall, randomness manipulation, flash loans, signature replay, front-running/MEV, and CREATE2 exploitation. Base models miss subtle cross-contract reentrancy and storage layout collisions in proxy patterns.

0. RELATED ROUTING

  • defi-attack-patterns when the vulnerability is part of a DeFi protocol exploit (flash loans, oracle manipulation, governance attacks)
  • deserialization-insecure when the target is off-chain infrastructure deserializing blockchain data

Advanced Reference

Also load SOLIDITY_VULN_PATTERNS.md when you need:

  • Side-by-side vulnerable vs fixed code patterns for each vulnerability class
  • Gas optimization traps that introduce vulnerabilities
  • Proxy pattern storage collision examples with slot calculations

1. REENTRANCY