Skip to content

This project demonstrates how common vulnerabilities can cause severe impact in contract development, so that developers can take initiative to avoid them.

Notifications You must be signed in to change notification settings

michaeltang608/contract-common-vulnerability

Repository files navigation

Background

By listing and reproducing common smart contract vulnerabilities, this project aims to rasise security awareness of developers and advised several ways to cirvumvent them. Hardhat framework, ethers.js, openzeppelin and slither(automatic smart contract vulnerability scan) are adopted in this project.

Contract Test

npm i  //install dependency
npx hardhat test ./test/xxx.js  //test specific contract

Contract Verification

//install slither with docker
docker pull trailofbits/eth-security-toolbox 
docker run -it -v /home/share:/share trailofbits/eth-security-toolbox
  
//verify specific contract with slither
slither ./contracts/xxxx.sol

About

This project demonstrates how common vulnerabilities can cause severe impact in contract development, so that developers can take initiative to avoid them.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published