5/5
_Follow along with this video:_ --- ### Setup Alright! To get things started, you know the drill. We'll be cloning our `Gas Bad NFT Marketplace` repo. ```bash git clone https://github.com/Cyfrin/3-gas-bad-nft-marketplace-audit.git cd 3-gas-bad-nft-marketplace-audit code . ``` We'll need to get our compiler prepared to use the correct version as well `0.8.20`. ```bash solc-select install 0.8.20 solc-select use 0.8.20 ``` > ❗ **PROTIP** > If you don't have solc-select installed, you can do so by following the steps outlined [**here**](https://github.com/crytic/solc-select). Your first step, once the repo is cloned locally, is to delete the `certora` folder. This is what we'll be walking through recreating together! Let's crack open the README to verify the setup steps recommended by the protocol. ::image{src='/formal-verification-3/2-setup//setup1.png' style='width: 100%; height: auto;'} The protocol wants us to use the `make` command! This should largely set our workspace up for us by removing old modules, installing our dependencies and building the project. > ❗ **WARNING** > Before running `make` we should always check our foundry.toml to assure `FFI=False`, running arbitrary code while our framework has these permissions is dangerous! **Be safe!** Lastly, before diving into the code base itself, we should see how the protocol's existing test suite looks. It seems they currently have BaseTest.t.sol which they are leveraging to compare their code bases and gas currently. Let's run it! ::image{src='/formal-verification-3/2-setup//setup2.png' style='width: 100%; height: auto;'} ### Wrap Up Things look good so far! Let's get begin taking a look at the code itself, in our next lesson! See you there!
We walk through setting up the Gas Bad NFT Marketplace locally and begin discussing the code base.
Previous lesson
Previous
Next lesson
Next
Give us feedback
Course Overview
About the course
Assembly
Writing smart contracts using Huff and Yul
Ethereum Virtual Machine OPCodes
Formal verification testing
Smart contract invariant testing
Halmos, Certora, Kontrol
Security researcher
$49,999 - $120,000 (avg. salary)
Smart Contract Auditor
$100,000 - $200,000 (avg. salary)
Guest lecturers:
Josselin Feist
Head of Blockchain at Trail of Bits
Last updated on May 28, 2025
Duration: 30min
Duration: 4h 38min
Duration: 3h 57min
Duration: 1h 56min
Course Overview
About the course
Assembly
Writing smart contracts using Huff and Yul
Ethereum Virtual Machine OPCodes
Formal verification testing
Smart contract invariant testing
Halmos, Certora, Kontrol
Security researcher
$49,999 - $120,000 (avg. salary)
Smart Contract Auditor
$100,000 - $200,000 (avg. salary)
Guest lecturers:
Josselin Feist
Head of Blockchain at Trail of Bits
Last updated on May 28, 2025