From buzz-crypto-bd
Fetches and analyzes Solidity/EVM smart contract source code via Etherscan/Sourcify, flags critical vulnerabilities, and enriches token scoring with audit summaries for a business development agent.
How this skill is triggered — by the user, by Claude, or both
Slash command
/buzz-crypto-bd:contract-auditorThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
> Fast security feedback on EVM token contracts. Findings in minutes, not weeks.
Fast security feedback on EVM token contracts. Findings in minutes, not weeks. Runs BEFORE
/score-tokenscoring. Enriches safety sub-agent output with on-chain proof.
When a token prospect arrives with a contract address, Buzz must NOT rely solely on RugCheck heuristics. This skill fetches the actual contract source and runs a structured security pass to surface high-confidence vulnerabilities that automated scanners miss or under-weight.
Time budget: < 3 minutes per contract
Output: Structured audit summary → piped into /score-token safety score
Revenue impact: Justifies premium /score-token pricing ($0.50–$1.00 via x402)
Run contract-auditor automatically when ANY of these conditions are met:
| Trigger | Condition |
|---|---|
/score-token called | Contract address provided + source is verified |
| Listing inquiry received | Prospect submits token for SolCex listing review |
| Safety sub-agent invoked | Scanner sub-agent passes contract to safety sub-agent |
| Manual request | Ogie asks Buzz to audit a specific contract address |
Skip if:
GET https://api.etherscan.io/api
?module=contract
&action=getsourcecode
&address={CONTRACT_ADDRESS}
&apikey={ETHERSCAN_API_KEY}
For Base chain:
GET https://api.basescan.org/api
?module=contract
&action=getsourcecode
&address={CONTRACT_ADDRESS}
&apikey={BASESCAN_API_KEY}
If not verified: Stop. Flag CONTRACT_NOT_VERIFIED as HIGH risk signal.
Add to score: -25 safety points. Report to Telegram and pipeline.
lines = source.split('\n').length
if lines > 5000: flag LARGE_CODEBASE, recommend manual audit, continue with partial scan
if lines < 50: flag SUSPICIOUSLY_SMALL, add to findings
Run ALL checks in Section 4. Log each finding with:
severity: CRITICAL | HIGH | MEDIUM | LOW | INFOpattern: the vulnerability classevidence: the specific function/line pattern foundconfidence: HIGH | MEDIUM | LOWbase_safety_score = 100
CRITICAL finding: -30 each (cap at -60)
HIGH finding: -15 each (cap at -30)
MEDIUM finding: -5 each
LOW finding: -2 each
CONTRACT_NOT_VERIFIED: -25 flat
LARGE_CODEBASE: -5 flat (uncertainty penalty)
Output the structured report (Section 5 format).
Pipe contract_safety_score and findings[] into the /score-token response.
Send Telegram summary to Ogie (@Ogie2) for any CRITICAL findings.
Read /contract-auditor/references/patterns.md for the full pattern library.
Quick reference — CRITICAL checks (always run these first):
| Check | Pattern to Find | Flag If... |
|---|---|---|
| Hidden Mint | mint(), _mint() outside constructor | Callable post-deploy by owner |
| Backdoor Transfer | transferFrom override, _transfer with owner bypass | Owner can move any wallet's tokens |
| Fee Trap | _taxFee, _liquidityFee > 25% or dynamically settable | Fees can be set to 100% |
| Blacklist | blacklist[], isBlacklisted, bots[] mapping | Owner can freeze arbitrary wallets |
| Pausable | pause(), whenNotPaused modifier | Owner can halt all transfers |
| Upgrade Proxy | upgradeTo(), _implementation, delegatecall | Contract logic replaceable post-deploy |
| Ownership Not Renounced | owner() != address(0) | Single point of control remains |
| Rug via LP | removeLiquidity callable by owner without timelock | Instant LP drain possible |
HIGH checks:
| Check | Pattern | Flag If... |
|---|---|---|
| Max TX Manipulation | _maxTxAmount setter | Settable to 0 (trading halt) |
| Unchecked Return | Low-level call() without return check | Silent failure on ETH send |
| Reentrancy | State change AFTER external call | Classic reentrancy shape |
| Integer Overflow | Pre-0.8.0 Solidity without SafeMath | Any arithmetic on token amounts |
| tx.origin Auth | require(tx.origin == owner) | Phishing vulnerability |
| Centralized Price Oracle | Single setPrice() owner function | Price manipulation |
{
"contract_audit": {
"address": "0x...",
"chain": "ethereum|base|bsc",
"verified": true,
"source_lines": 847,
"compiler": "v0.8.19",
"scan_timestamp": "2026-03-06T12:00:00Z",
"contract_safety_score": 72,
"risk_level": "MEDIUM",
"findings": [
{
"severity": "HIGH",
"pattern": "BLACKLIST",
"evidence": "function addToBlacklist(address account) external onlyOwner",
"confidence": "HIGH",
"description": "Owner can blacklist arbitrary wallet addresses, freezing their tokens"
}
],
"flags": ["OWNERSHIP_NOT_RENOUNCED"],
"recommendation": "REVIEW_REQUIRED",
"audit_summary": "Contract has standard ERC-20 structure with 1 HIGH finding (blacklist mechanism). Ownership not renounced. Recommend requesting renouncement before listing.",
"listing_recommendation": "CONDITIONAL"
}
}
listing_recommendation values:
APPROVE — No CRITICAL/HIGH findings, ownership renouncedCONDITIONAL — HIGH findings present but mitigable, or ownership not renouncedREJECT — CRITICAL findings, or contract not verifiedESCALATE — Unusual patterns requiring human reviewContract source auditing does NOT apply to Solana SPL tokens. For SPL tokens, use this alternative safety chain:
mintAuthority: null = frozen = GOOD)freezeAuthority: null = GOOD)rugcheck.xyz/tokens/{mint}) — Full rug scoreFlag MINT_AUTHORITY_ACTIVE as HIGH risk if mintAuthority is not null.
Flag FREEZE_AUTHORITY_ACTIVE as HIGH risk if freezeAuthority is not null.
Audit results are stored in SQLite and exposed via:
GET /api/v1/audit/{address}
POST /api/v1/audit/run { "address": "0x...", "chain": "base" }
contract_safety_score from this skill feeds into /score-token response:
final_safety_score = (rugcheck_score * 0.4) + (contract_audit_score * 0.6)
Contract audit carries MORE weight than RugCheck because it's source-level.
After every audit, log to JVR receipt system:
AUDIT_COMPLETE | {address} | score:{N} | findings:{N} | {recommendation}
Send Telegram notification to Ogie for any CRITICAL findings or REJECT recommendations.
Tell prospects clearly:
"Buzz contract analysis is pattern-based AI scanning — strong at detecting known vulnerability shapes (hidden mints, blacklists, fee traps, reentrancy). It cannot detect multi-transaction state exploits, game-theory attacks, cross-protocol composability risks, or off-chain assumption bugs. For high-value listings, a formal audit from Pashov, Code4rena, or Sherlock is strongly recommended."
When a contract has HIGH/CRITICAL findings or is > 3,000 lines:
Contract Auditor Skill v1.0 — Indonesia Sprint Day 9
For Buzz BD Agent v6.2.1-bnb | SolCex Exchange
Pattern library: references/patterns.md
"Catch what humans forget to check."
npx claudepluginhub buzzbysolcex/buzz-bd-agentProvides CDSS development patterns for drug interaction checking, dose validation, clinical scoring (NEWS2, qSOFA), and alert classification integrated into EMR workflows.