{"repo":"minaminao/ctf-blockchain","free":true,"listed":false,"github":"https://github.com/minaminao/ctf-blockchain","clone":"git clone https://github.com/minaminao/ctf-blockchain.git","description":"A summary and solutions for 200+ CTF blockchain challenges","language":"Solidity","stars":1090,"topics":["ctf","blockchain","ethereum","solidity","evm"],"license":null,"category":"blockchain-web3","readme_excerpt":"CTF Blockchain Challenges This repository collects blockchain challenges in CTFs and wargames. These challenges are categorized by topic, not by difficulty or recommendation. Some of them include personal writeups and solutions (e.g., Paradigm CTF 2022). Please be aware that these contain spoilers. --- Table of Contents - CTF List - Ethereum - Smart contract basics - EVM puzzles - Misuse of tx.origin - Weak sources of randomness from chain attributes - ERC-20 basics - Storage overwrite by delegatecall - Context mismatch in delegatecall - Integer overflow - Ether transfer failures for non-payable contracts - Forced Ether transfers to non-payable contracts via selfdestruct - Large gas consumption by contract callees - Forgetting to set view / pure to interface and abstract contract functions - Missing success flag checks in low-level calls - view functions that do not always return same values - Mistakes in setting storage and memory - Tracing transactions - Reversing states - Reversing transactions - Reversing EVM bytecodes - EVM assembly logic bugs - EVM bytecode golf - Jump-oriented programming - Gas optimization - Collisions when using abi.encodePacked with variable length arguments - Bypassing verifications with zero iteration loops - Reentrancy attacks - Flash loan basics - Governance attacks by executing flash loans during snapshots - Bypassing repayments of push architecture flash loans - Bugs in AMM price calculation algorithm - Attacks using custom tokens - Oracle man","default_branch":null,"files":null,"tree":[],"storefront":"/r/minaminao","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/minaminao/ctf-blockchain/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}