This is work in progress (WIP). The framework is still in its infancy, the scripts are unpolished bash, quirky, etc.
We invite you to help. Please see also section "contribution".
- more flexibility in various aspects
- test cases can be run against different networks, but also against the pytezos interpreter, etc.
- test cases can be run at any time
- test cases can be run using different Ligo / SmartPy compilers
- possibility to run only a subset of test cases
- improving result checking
- improving output
- reusing already deployed contracts (mainnet?)
- tracking / comparing changes between different environments/setups (protocols, compilers, etc.
- etc.
The purpose of the Tezos security baseline checking framework is to check whether the underlying system for smart contracts on Tezos continues to behave as expected.
Performing these checks independently is crucial for smart contract developers and, in particular, for security assessors in order to understand how the underlying system is working and whether it has been changed. Thus, a profound understanding of the underlying system forms a "baseline" for any security-related work on smart contracts.
For instance the Tezos security assessment checklist is based on this baseline and can potentially need to be updated as soon as the underlying system's mechanics have changed.
An additional benefit of this independent security baseline checking framework is the early detection of critical changes to the underlying system for smart contract in the development of new Tezos protocols, high-level smart contract compilers, etc.
An overview over existing test cases can be found in ./index.md
-
Download this repo:
git clone https://github.com/Inference/TezosSecurityBaselineCheckingFramework
-
Get a tezos-client executable, which supports the network where you want to run the test cases on.
-
Install SmartPy
-
Install Ligo
-
Adapt parameters for SMARTPY, LIGO, and TEZOSCLIENT in the _framework/init.sh file.
-
Download two test accounts from the corresponding testnet faucet, name one "admin.json" and the other "deploy.json, and store these files under ./_framework/
-
Change to the _framework directory E.g.
cd _framework
-
Execute script
./import.sh
to import and activate the downloaded test accounts.
- Change to the _framework directory:
cd _framework
- Execute the script
./execute_all.sh
- Change to the test case directory. E.g.
cd testcases/TC-001]
- Execute the script
./execute_test.sh
Everyone is invited to contribute to the security baseline checking framework. We are eager to see new ideas, read new test cases and foster the development of the framework by everyone in the Tezos ecosystem.
This security baseline checking framework is currently "work in progress". The security baseline checking framework does not claim to be complete at any time as it is continuously developed.
This github repository is currently maintained by Inference.