Skip to content
master
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.

SlimChain

WARNING: This is an academic proof-of-concept prototype, and in particular has not received careful code review. This implementation is NOT ready for production use.

If you find the code here useful, please consider to cite our paper:

@article{PVLDB:slimchain,
  author = {Xu, Cheng and Zhang, Ce and Xu, Jianliang and Pei, Jian},
  title = {{SlimChain}: Scaling Blockchain Transactions through Off-Chain Storage and Parallel Processing},
  journal = {Proceedings of the VLDB Endowment},
  year = {2021},
  month = jul,
  volume = {14},
  number = {11},
  pages = {2314--2326},
  issn = {2150-8097},
  doi = {10.14778/3476249.3476283}
}

Install Dependencies

  • OS: Ubuntu 18.04 LTS or Ubuntu 20.04 LTS.
  • Install Rust.
  • Run sudo ./scripts/install_deps.sh.
  • Install SGX Driver by running sudo ./scripts/install_sgx_driver.sh.
  • Enable SGX Aesm service: sudo /opt/intel/sgx-aesm-service/startup.sh.

Build and Test

  • Create a minimal config.toml file in the root directory with the following content:
# Obtain keys from https://api.portal.trustedservices.intel.com/EPID-attestation
[tee]
# Subscription Key that provides access to the Intel API
api_key = "YOUR_API_KEY"
# Service Provider ID (SPID)
spid = "YOUR_SPID"
# Whether to sign linkable quote
linkable = false
  • Run the following commands.
make
make test-release

Run Nodes

  • Create proper config.toml file based on examples from config-example.
  • See help messages on how to run nodes and send txs:
./target/release/slimchain-node-tee --help # run slimchain nodes
./target/release/slimchain-send-tx --help # send tx
./target/release/baseline-classic-node --help # run baseline (classic) nodes
./target/release/baseline-stateful-node-tee --help # run baseline (stateful) nodes
./target/release/slimchain-inspect-db --help # check storage size

Adjust Proof-of-Work Difficulty

You can change the initial Proof-of-Work difficulty in the config.toml.

To test the difficulty:

cargo test --release -p slimchain-chain consensus::pow::tests::test_pow  -- --nocapture --exact --ignored

About

Source code for the VLDB21 paper "SlimChain: Scaling Blockchain Transactions through Off-Chain Storage and Parallel Processing"

Topics

Resources

License

Releases

No releases published

Packages

No packages published